File ppp-2.4.2-misc.diff of Package ppp

--- pppd/utils.c
+++ pppd/utils.c
@@ -295,7 +295,7 @@
 #if 0	/* not used, and breaks on S/390, apparently */
 	case 'r':
 	    f = va_arg(args, char *);
-#ifndef __powerpc__
+#if !defined __powerpc__ && !defined __x86_64__ && !defined __s390__ && !defined __s390x__
 	    n = vslprintf(buf, buflen + 1, f, va_arg(args, va_list));
 #else
 	    /* On the powerpc, a va_list is an array of 1 structure */
--- pppd/auth.c
+++ pppd/auth.c
@@ -1626,9 +1626,10 @@
 
     if (fstat(fileno(f), &sbuf) < 0) {
 	warn("cannot stat secret file %s: %m", filename);
-    } else if ((sbuf.st_mode & (S_IRWXG | S_IRWXO)) != 0) {
-	warn("Warning - secret file %s has world and/or group access",
-	     filename);
+    } else if ((sbuf.st_mode & S_IRWXO) != 0) {
+	warn("Warning - secret file %s has world access", filename);
+    } else if ((sbuf.st_mode & S_IRWXG) != 0 && sbuf.st_gid != 15) {
+	warn("Warning - secret file %s has group access", filename);
     }
 }
 
--- pppd/lcp.c
+++ pppd/lcp.c
@@ -1876,7 +1876,7 @@
     if (lcp_gotoptions[f->unit].neg_magicnumber
 	&& magic == lcp_gotoptions[f->unit].magicnumber) {
 	warn("appear to have received our own echo-reply!");
-	return;
+	/* M$-Software did get this wrong so we also accept those packets. */
     }
 
     /* Reset the number of outstanding echo frames */
--- pppd/pppd.h
+++ pppd/pppd.h
@@ -589,15 +589,7 @@
 #define DEBUGCHAP	1
 #endif
 
-#ifndef LOG_PPP			/* we use LOG_LOCAL2 for syslog by default */
-#if defined(DEBUGMAIN) || defined(DEBUGFSM) || defined(DEBUGSYS) \
-  || defined(DEBUGLCP) || defined(DEBUGIPCP) || defined(DEBUGUPAP) \
-  || defined(DEBUGCHAP) || defined(DEBUG) || defined(DEBUGIPV6CP)
 #define LOG_PPP LOG_LOCAL2
-#else
-#define LOG_PPP LOG_DAEMON
-#endif
-#endif /* LOG_PPP */
 
 #ifdef DEBUGMAIN
 #define MAINDEBUG(x)	if (debug) dbglog x
--- pppdump/pppdump.c
+++ pppdump/pppdump.c
@@ -191,7 +191,7 @@
 	    show_time(f, c);
 	    break;
 	default:
-	    printf("?%.2x\n");
+	    printf("?%.2x\n", c);
 	}
     }
 }
@@ -421,7 +421,7 @@
 	    show_time(f, c);
 	    break;
 	default:
-	    printf("?%.2x\n");
+	    printf("?%.2x\n", c);
 	}
     }
 }
--- pppdump/bsd-comp.c
+++ pppdump/bsd-comp.c
@@ -560,7 +560,8 @@
     u_int incode, oldcode, finchar;
     u_char *p, *rptr, *wptr;
     int ilen;
-    int dlen, space, codelen, extra;
+    int dlen = 0;
+    int space, codelen, extra;

     rptr = cmsg;
     if (*rptr == 0)

openSUSE Build Service is sponsored by