mirror of
https://github.com/yann64/haikuports.git
synced 2026-05-04 22:18:55 +02:00
109 lines
3.7 KiB
Diff
109 lines
3.7 KiB
Diff
diff -ur transmission-2.82/libtransmission/platform-quota.c transmission-2.82-haiku/libtransmission/platform-quota.c
|
|
--- transmission-2.82/libtransmission/platform-quota.c 2013-08-09 02:45:44.822345728 +0000
|
|
+++ transmission-2.82-haiku/libtransmission/platform-quota.c 2013-12-27 10:29:53.872415232 +0000
|
|
@@ -16,7 +16,7 @@
|
|
#include <unistd.h> /* getuid() */
|
|
#include <event2/util.h> /* evutil_ascii_strcasecmp () */
|
|
|
|
-#ifndef WIN32
|
|
+#if !defined(WIN32) && !defined(__HAIKU__)
|
|
#include <sys/types.h> /* types needed by quota.h */
|
|
#if defined(__FreeBSD__) || defined(__OpenBSD__)
|
|
#include <ufs/ufs/quota.h> /* quotactl() */
|
|
@@ -67,7 +67,7 @@
|
|
****
|
|
***/
|
|
|
|
-#ifndef WIN32
|
|
+#if !defined(WIN32) && !defined(__HAIKU__)
|
|
static const char *
|
|
getdev (const char * path)
|
|
{
|
|
@@ -300,7 +300,7 @@
|
|
{
|
|
int64_t ret = -1;
|
|
|
|
-#ifndef WIN32
|
|
+#if !defined(WIN32) && !defined(__HAIKU__)
|
|
|
|
if (info->fstype && !evutil_ascii_strcasecmp(info->fstype, "xfs"))
|
|
{
|
|
@@ -347,7 +347,7 @@
|
|
|
|
info = tr_new0 (struct tr_device_info, 1);
|
|
info->path = tr_strdup (path);
|
|
-#ifndef WIN32
|
|
+#if !defined(WIN32) && !defined(__HAIKU__)
|
|
info->device = tr_strdup (getblkdev (path));
|
|
info->fstype = tr_strdup (getfstype (path));
|
|
#endif
|
|
diff -ur transmission-2.82/third-party/miniupnp/connecthostport.c transmission-2.82-haiku/third-party/miniupnp/connecthostport.c
|
|
--- transmission-2.82/third-party/miniupnp/connecthostport.c 2013-08-09 02:47:50.398196736 +0000
|
|
+++ transmission-2.82-haiku/third-party/miniupnp/connecthostport.c 2013-12-27 10:30:00.589037568 +0000
|
|
@@ -24,6 +24,7 @@
|
|
#else /* #ifdef _WIN32 */
|
|
#include <unistd.h>
|
|
#include <sys/param.h>
|
|
+#include <sys/select.h>
|
|
#include <errno.h>
|
|
#define closesocket close
|
|
#include <netdb.h>
|
|
diff -ur transmission-2.82/third-party/miniupnp/miniupnpc.c transmission-2.82-haiku/third-party/miniupnp/miniupnpc.c
|
|
--- transmission-2.82/third-party/miniupnp/miniupnpc.c 2013-08-09 02:47:50.894435328 +0000
|
|
+++ transmission-2.82-haiku/third-party/miniupnp/miniupnpc.c 2013-12-27 10:30:00.625737728 +0000
|
|
@@ -17,7 +17,7 @@
|
|
#endif
|
|
#endif
|
|
|
|
-#if !defined(__OpenBSD__) && !defined(__NetBSD__) && !defined(MACOSX) && !defined(_WIN32) && !defined(__CYGWIN__) && !defined(__sun)
|
|
+#if !defined(__OpenBSD__) && !defined(__NetBSD__) && !defined(MACOSX) && !defined(_WIN32) && !defined(__CYGWIN__) && !defined(__sun) && !defined(__HAIKU__)
|
|
#define HAS_IP_MREQN
|
|
#endif
|
|
|
|
diff -ur transmission-2.82/third-party/miniupnp/portlistingparse.c transmission-2.82-haiku/third-party/miniupnp/portlistingparse.c
|
|
--- transmission-2.82/third-party/miniupnp/portlistingparse.c 2013-08-09 02:47:50.074186752 +0000
|
|
+++ transmission-2.82-haiku/third-party/miniupnp/portlistingparse.c 2013-12-27 10:30:00.638582784 +0000
|
|
@@ -28,7 +28,7 @@
|
|
|
|
/* Helper function */
|
|
static UNSIGNED_INTEGER
|
|
-atoui(const char * p, int l)
|
|
+my_atoui(const char * p, int l)
|
|
{
|
|
UNSIGNED_INTEGER r = 0;
|
|
while(l > 0 && *p)
|
|
@@ -92,7 +92,7 @@
|
|
pm->remoteHost[l] = '\0';
|
|
break;
|
|
case NewExternalPort:
|
|
- pm->externalPort = (unsigned short)atoui(data, l);
|
|
+ pm->externalPort = (unsigned short)my_atoui(data, l);
|
|
break;
|
|
case NewProtocol:
|
|
if(l > 3)
|
|
@@ -101,21 +101,21 @@
|
|
pm->protocol[l] = '\0';
|
|
break;
|
|
case NewInternalPort:
|
|
- pm->internalPort = (unsigned short)atoui(data, l);
|
|
+ pm->internalPort = (unsigned short)my_atoui(data, l);
|
|
break;
|
|
case NewInternalClient:
|
|
memcpy(pm->internalClient, data, l);
|
|
pm->internalClient[l] = '\0';
|
|
break;
|
|
case NewEnabled:
|
|
- pm->enabled = (unsigned char)atoui(data, l);
|
|
+ pm->enabled = (unsigned char)my_atoui(data, l);
|
|
break;
|
|
case NewDescription:
|
|
memcpy(pm->description, data, l);
|
|
pm->description[l] = '\0';
|
|
break;
|
|
case NewLeaseTime:
|
|
- pm->leaseTime = atoui(data, l);
|
|
+ pm->leaseTime = my_atoui(data, l);
|
|
break;
|
|
default:
|
|
break;
|