diff options
author | hubertf <hubertf@pkgsrc.org> | 1998-10-02 06:47:29 +0000 |
---|---|---|
committer | hubertf <hubertf@pkgsrc.org> | 1998-10-02 06:47:29 +0000 |
commit | f66a2e85c2acf1af9c91cef93677427a346b7c74 (patch) | |
tree | 5332efacb40d73fb856bb11aacf99301a21cb08f /mbone/sdr/patches/patch-ad | |
parent | 3855b63dd960944bd916b1fb15c20306b99d7c41 (diff) | |
download | pkgsrc-f66a2e85c2acf1af9c91cef93677427a346b7c74.tar.gz |
work around <sys/inttypes.h> not present in 1.3
Diffstat (limited to 'mbone/sdr/patches/patch-ad')
-rw-r--r-- | mbone/sdr/patches/patch-ad | 29 |
1 files changed, 19 insertions, 10 deletions
diff --git a/mbone/sdr/patches/patch-ad b/mbone/sdr/patches/patch-ad index ad8bc96c5d7..65e4fb1091a 100644 --- a/mbone/sdr/patches/patch-ad +++ b/mbone/sdr/patches/patch-ad @@ -1,26 +1,35 @@ -$NetBSD: patch-ad,v 1.3 1998/09/13 18:02:10 garbled Exp $ ---- src/sd_listen.c.orig Sun Sep 13 10:34:47 1998 -+++ src/sd_listen.c Sun Sep 13 10:37:01 1998 -@@ -316,10 +316,10 @@ +$NetBSD +--- src/sd_listen.c.orig Thu Jan 8 20:39:21 1998 ++++ src/sd_listen.c Fri Oct 2 08:30:50 1998 +@@ -316,11 +316,19 @@ if (strncmp(k1, "k=", 2)==0) { -- if ((u_int)k2>=(u_int)k1+2) ++#ifdef HAVE_SYS_INTTYPES_H + if ((uintptr_t)k2>=(uintptr_t)k1+2) - { -- memcpy(key, k1+2, (u_int)k2-((u_int)k1+1)); -- key[(u_int)k2-((u_int)k1+1)]='\0'; ++ { + memcpy(key, k1+2, (uintptr_t)k2-((uintptr_t)k1+1)); + key[(uintptr_t)k2-((uintptr_t)k1+1)]='\0'; ++ } ++#else + if ((u_int)k2>=(u_int)k1+2) + { + memcpy(key, k1+2, (u_int)k2-((u_int)k1+1)); + key[(u_int)k2-((u_int)k1+1)]='\0'; } ++#endif else { -@@ -648,7 +648,7 @@ + key[0]='\0'; +@@ -648,7 +656,11 @@ struct timeval tv; unsigned long src, hfrom; char *data; -- int ix = rfd2sock[PTOI(fd)]; ++#ifdef HAVE_SYS_INTTYPES_H + intptr_t ix = rfd2sock[PTOI(fd)]; ++#else + int ix = rfd2sock[PTOI(fd)]; ++#endif fromlen=sizeof(struct sockaddr); |