radiusclient/radiusclient.patch.libc

changeset 18
9115bae56135
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/radiusclient/radiusclient.patch.libc	Tue Jan 06 23:48:04 2009 +0100
     1.3 @@ -0,0 +1,20 @@
     1.4 +Index: lib/buildreq.c
     1.5 +--- lib/buildreq.c.orig	2005-07-21 01:01:07.000000000 -0700
     1.6 ++++ lib/buildreq.c	2008-02-23 16:33:08.000000000 -0800
     1.7 +@@ -89,10 +89,14 @@
     1.8 + 	}
     1.9 + 
    1.10 + 	rewind(sf);
    1.11 +-	if (fscanf(sf, "%d", &seq_nbr) != 1) {
    1.12 ++	/* comment the following block out to work around some broken */
    1.13 ++	/* libc distros which return 0 on successful fscanf(3) calls, */
    1.14 ++	/* and use the simple replacement follwing the block instead. */
    1.15 ++	/*if (fscanf(sf, "%d", &seq_nbr) != 1) {
    1.16 + 		rc_log(LOG_ERR,"rc_get_seqnbr: fscanf failure: %s", seqfile);
    1.17 + 		seq_nbr = rc_guess_seqnbr();
    1.18 +-	}
    1.19 ++	}*/
    1.20 ++	fscanf(sf, "%d", &seq_nbr);
    1.21 + 
    1.22 + 	rewind(sf);
    1.23 + 	ftruncate(fileno(sf),0);

mercurial