Import of pkgsrc-2015Q2
This commit is contained in:
@@ -1,9 +1,7 @@
|
||||
# $NetBSD: Makefile,v 1.7 2015/03/13 16:35:39 tnn Exp $
|
||||
# $NetBSD: Makefile,v 1.8 2015/04/06 02:26:53 rodent Exp $
|
||||
#
|
||||
|
||||
DISTNAME= 3proxy-0.5.3k
|
||||
PKGNAME= ${DISTNAME:C/k$/.11/}
|
||||
PKGREVISION= 1
|
||||
DISTNAME= 3proxy-0.7.1.2
|
||||
CATEGORIES= net
|
||||
MASTER_SITES= http://3proxy.ru/${DISTNAME:S/3proxy-//}/
|
||||
EXTRACT_SUFX= .tgz
|
||||
@@ -17,7 +15,7 @@ COMMENT= Multi-protocol proxy
|
||||
# number. 3proxy-0.6.* will have a different license.
|
||||
LICENSE= 3proxy-0.5-license
|
||||
|
||||
WRKSRC= ${WRKDIR}
|
||||
WRKSRC= ${WRKDIR}/${PKGBASE}
|
||||
MAKE_FILE= Makefile.unix
|
||||
|
||||
INSTALLATION_DIRS= sbin ${PKGMANDIR}/man5 ${PKGMANDIR}/man8
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
$NetBSD: distinfo,v 1.2 2008/02/27 23:50:29 apb Exp $
|
||||
$NetBSD: distinfo,v 1.3 2015/04/06 02:26:53 rodent Exp $
|
||||
|
||||
SHA1 (3proxy-0.5.3k.tgz) = 71befdaa94867e4b54a5b24e2a3b3b33debd5e67
|
||||
RMD160 (3proxy-0.5.3k.tgz) = 416d3c0d870a6aa450472f4ab060ce90e3362dea
|
||||
Size (3proxy-0.5.3k.tgz) = 190797 bytes
|
||||
SHA1 (patch-aa) = e84a56ce0ce1fc82c982fb0e78ea14986035e0a0
|
||||
SHA1 (patch-ab) = 681c7b0b29ad6fb652b3fa8bcecc2af563589c4f
|
||||
SHA1 (patch-ac) = caff37ccb6018152d11f6ce5c682f8cec4feff9b
|
||||
SHA1 (patch-ad) = e5ebc2defdf5a79ff21e37101ddbee5f212d64f1
|
||||
SHA1 (patch-ae) = 03b9d88bd316fda6b812bbe29dbe471a652cfe91
|
||||
SHA1 (3proxy-0.7.1.2.tgz) = 58d92a3b61767c83a16f2cfd784458972083c63b
|
||||
RMD160 (3proxy-0.7.1.2.tgz) = a3be3d2c786cc52bfde46b7f9630a79eaf7b983c
|
||||
Size (3proxy-0.7.1.2.tgz) = 478532 bytes
|
||||
SHA1 (patch-aa) = ac13f04cff2fa0b0adea6306d9f645ff26452daa
|
||||
SHA1 (patch-ab) = de12687ae56ed8107259a4bc3ca04705b97b7bc8
|
||||
SHA1 (patch-ac) = 3b8479dd2cf736a87e618128e91f402611178236
|
||||
SHA1 (patch-ad) = bce24c6e2e071196d8fd0715e11f4c68144150c5
|
||||
SHA1 (patch-ae) = ef3236744582bd717db1329b7b6ad68c82156d55
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
$NetBSD: patch-aa,v 1.1 2008/02/27 16:14:25 apb Exp $
|
||||
$NetBSD: patch-aa,v 1.2 2015/04/06 02:26:53 rodent Exp $
|
||||
|
||||
--- src/3proxy.c.orig 2007-04-20 13:05:10.000000000 +0200
|
||||
--- src/3proxy.c.orig 2015-02-17 13:07:20.000000000 +0000
|
||||
+++ src/3proxy.c
|
||||
@@ -1276,7 +1276,7 @@ int readconfig(FILE * fp){
|
||||
|
||||
|
||||
tl->comment = mystrdup((char *)ch->argv[1]);
|
||||
- while(isdigit(*tl->comment))tl->comment++;
|
||||
+ while(isdigit((unsigned char)*tl->comment))tl->comment++;
|
||||
if(*tl->comment== '/')tl->comment++;
|
||||
|
||||
sscanf((char *)ch->argv[1], "%u", &tl->number);
|
||||
@@ -1550,7 +1550,7 @@ static int h_ace(int argc, unsigned char
|
||||
unsigned long lim;
|
||||
|
||||
tl->comment = ( char *)argv[1];
|
||||
- while(isdigit(*tl->comment))tl->comment++;
|
||||
+ while(isdigit((unsigned char)*tl->comment))tl->comment++;
|
||||
if(*tl->comment== '/')tl->comment++;
|
||||
tl->comment = mystrdup(tl->comment);
|
||||
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
$NetBSD: patch-ab,v 1.1 2008/02/27 16:14:25 apb Exp $
|
||||
$NetBSD: patch-ab,v 1.2 2015/04/06 02:26:53 rodent Exp $
|
||||
|
||||
--- src/ntlm.c.orig 2006-10-15 10:40:04.000000000 +0200
|
||||
--- src/ntlm.c.orig 2015-02-17 13:07:21.000000000 +0000
|
||||
+++ src/ntlm.c
|
||||
@@ -43,7 +43,7 @@ int text2unicode(const char * text, char
|
||||
buflen = ((buflen>>1)<<1);
|
||||
if(!text || !buflen) return 0;
|
||||
do {
|
||||
- buf[count++] = toupper(*text++);
|
||||
+ buf[count++] = toupper((unsigned char)*text++);
|
||||
buf[count++] = '\0';
|
||||
} while (*text && count < buflen);
|
||||
return count;
|
||||
buflen = ((buflen>>1)<<1);
|
||||
if(!text || !buflen) return 0;
|
||||
do {
|
||||
- buf[count++] = toupper(*text++);
|
||||
+ buf[count++] = toupper((unsigned char)*text++);
|
||||
buf[count++] = '\0';
|
||||
} while (*text && count < buflen);
|
||||
return count;
|
||||
|
||||
@@ -1,34 +1,34 @@
|
||||
$NetBSD: patch-ac,v 1.1 2008/02/27 16:14:25 apb Exp $
|
||||
$NetBSD: patch-ac,v 1.2 2015/04/06 02:26:53 rodent Exp $
|
||||
|
||||
--- src/webadmin.c.orig 2006-03-10 21:36:33.000000000 +0200
|
||||
--- src/webadmin.c.orig 2015-02-17 13:07:21.000000000 +0000
|
||||
+++ src/webadmin.c
|
||||
@@ -311,12 +311,12 @@ void * adminchild(void * data) {
|
||||
sb = strchr(buf, ':');
|
||||
if(!sb)continue;
|
||||
++sb;
|
||||
- while(isspace(*sb))sb++;
|
||||
+ while(isspace((unsigned char)*sb))sb++;
|
||||
if(!*sb || strncasecmp(sb, "basic", 5)){
|
||||
continue;
|
||||
}
|
||||
sb+=5;
|
||||
- while(isspace(*sb))sb++;
|
||||
+ while(isspace((unsigned char)*sb))sb++;
|
||||
i = de64((unsigned char *)sb, (unsigned char *)username, 255);
|
||||
if(i<=0)continue;
|
||||
username[i] = 0;
|
||||
@@ -332,12 +332,12 @@ void * adminchild(void * data) {
|
||||
}
|
||||
else if(i > 15 && (!strncasecmp(buf, "content-length:", 15))){
|
||||
sb = buf + 15;
|
||||
- while(isspace(*sb))sb++;
|
||||
+ while(isspace((unsigned char)*sb))sb++;
|
||||
contentlen = atoi(sb);
|
||||
}
|
||||
else if(i > 13 && (!strncasecmp(buf, "content-type:", 13))){
|
||||
sb = buf + 13;
|
||||
- while(isspace(*sb))sb++;
|
||||
+ while(isspace((unsigned char)*sb))sb++;
|
||||
if(!strncasecmp(sb, "x-www-form-urlencoded", 21)) isform = 1;
|
||||
}
|
||||
}
|
||||
@@ -375,12 +375,12 @@ void * adminchild(struct clientparam* pa
|
||||
sb = strchr(buf, ':');
|
||||
if(!sb)continue;
|
||||
++sb;
|
||||
- while(isspace(*sb))sb++;
|
||||
+ while(isspace((unsigned char)*sb))sb++;
|
||||
if(!*sb || strncasecmp(sb, "basic", 5)){
|
||||
continue;
|
||||
}
|
||||
sb+=5;
|
||||
- while(isspace(*sb))sb++;
|
||||
+ while(isspace((unsigned char)*sb))sb++;
|
||||
i = de64((unsigned char *)sb, (unsigned char *)username, 255);
|
||||
if(i<=0)continue;
|
||||
username[i] = 0;
|
||||
@@ -396,12 +396,12 @@ void * adminchild(struct clientparam* pa
|
||||
}
|
||||
else if(i > 15 && (!strncasecmp(buf, "content-length:", 15))){
|
||||
sb = buf + 15;
|
||||
- while(isspace(*sb))sb++;
|
||||
+ while(isspace((unsigned char)*sb))sb++;
|
||||
contentlen = atoi(sb);
|
||||
}
|
||||
else if(i > 13 && (!strncasecmp(buf, "content-type:", 13))){
|
||||
sb = buf + 13;
|
||||
- while(isspace(*sb))sb++;
|
||||
+ while(isspace((unsigned char)*sb))sb++;
|
||||
if(!strncasecmp(sb, "x-www-form-urlencoded", 21)) isform = 1;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,27 +1,26 @@
|
||||
$NetBSD: patch-ad,v 1.1 2008/02/27 23:50:29 apb Exp $
|
||||
$NetBSD: patch-ad,v 1.2 2015/04/06 02:26:53 rodent Exp $
|
||||
|
||||
--- src/common.c.orig 2008-01-08 18:57:30.000000000 +0200
|
||||
--- src/common.c.orig 2015-02-17 13:07:20.000000000 +0000
|
||||
+++ src/common.c
|
||||
@@ -606,3 +606,22 @@ unsigned long getip(unsigned char *name)
|
||||
#endif
|
||||
return retval;
|
||||
}
|
||||
+
|
||||
+/*
|
||||
+ * POSIX says:
|
||||
+ * The usleep() function may fail if:
|
||||
+ * [EINVAL] The time interval specified one million or more microseconds.
|
||||
+ *
|
||||
+ * Other code in 3proxy calls usleep with much larger arguments, but
|
||||
+ * that gets redirected here via "#define usleep(usecs) myusleep(usecs)"
|
||||
+ * in proxy.h. We call sleep() for any whole number of seconds, and
|
||||
+ * the real usleep() for any left over microseconds.
|
||||
+ */
|
||||
+int
|
||||
+myusleep(useconds_t useconds)
|
||||
+{
|
||||
+ unsigned int secs = useconds / 1000000;
|
||||
+ useconds = useconds % 1000000;
|
||||
+ if (secs > 0) sleep(secs);
|
||||
+ return (usleep)(useconds);
|
||||
+}
|
||||
@@ -719,3 +719,21 @@ unsigned long getip(unsigned char *name)
|
||||
#endif
|
||||
return retval;
|
||||
}
|
||||
+
|
||||
+/*
|
||||
+ * POSIX says:
|
||||
+ * The usleep() function may fail if:
|
||||
+ * [EINVAL] The time interval specified one million or more microseconds.
|
||||
+ *
|
||||
+ * Other code in 3proxy calls usleep with much larger arguments, but
|
||||
+ * that gets redirected here via "#define usleep(usecs) myusleep(usecs)"
|
||||
+ * in proxy.h. We call sleep() for any whole number of seconds, and
|
||||
+ * the real usleep() for any left over microseconds.
|
||||
+ */
|
||||
+int myusleep(useconds_t useconds)
|
||||
+{
|
||||
+ unsigned int secs = useconds / 1000000;
|
||||
+ useconds = useconds % 1000000;
|
||||
+ if (secs > 0) sleep(secs);
|
||||
+ return (usleep)(useconds);
|
||||
+}
|
||||
|
||||
@@ -1,13 +1,23 @@
|
||||
$NetBSD: patch-ae,v 1.1 2008/02/27 23:50:29 apb Exp $
|
||||
|
||||
--- src/proxy.h.orig 2006-09-21 14:32:05.000000000 +0200
|
||||
+++ src/proxy.h
|
||||
@@ -95,6 +95,8 @@
|
||||
#endif
|
||||
#define daemonize() daemon(1,1)
|
||||
#define SLEEPTIME 1000
|
||||
+#define usleep(usecs) myusleep(usecs)
|
||||
+int myusleep(useconds_t);
|
||||
#ifndef O_BINARY
|
||||
#define O_BINARY 0
|
||||
#endif
|
||||
$NetBSD: patch-ae,v 1.2 2015/04/06 02:26:53 rodent Exp $
|
||||
|
||||
--- src/proxy.h.orig 2015-02-17 13:07:21.000000000 +0000
|
||||
+++ src/proxy.h
|
||||
@@ -22,7 +22,9 @@
|
||||
#include <ctype.h>
|
||||
#include <sys/types.h>
|
||||
#include <sys/stat.h>
|
||||
+#if !(defined(__OpenBSD__) || !defined(__Bitrig__))
|
||||
#include <sys/timeb.h>
|
||||
+#endif
|
||||
#include <fcntl.h>
|
||||
#include <time.h>
|
||||
|
||||
@@ -101,6 +103,8 @@
|
||||
#endif
|
||||
#define daemonize() daemon(1,1)
|
||||
#define SLEEPTIME 1000
|
||||
+#define usleep(usecs) myusleep(usecs)
|
||||
+int myusleep(useconds_t);
|
||||
#ifndef O_BINARY
|
||||
#define O_BINARY 0
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user