Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 41960 Details for
Bug 65892
(toolchain) glibc propolice patch has unwanted side-effects
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Proposed fix for ssp.c.
ssp.sck-read-once.fix.patch (text/plain), 3.01 KB, created by
Lorenzo Hernández García-Hierro
on 2004-10-16 07:48:40 UTC
(
hide
)
Description:
Proposed fix for ssp.c.
Filename:
MIME Type:
Creator:
Lorenzo Hernández García-Hierro
Created:
2004-10-16 07:48:40 UTC
Size:
3.01 KB
patch
obsolete
>--- ssp.c.orig 2004-09-29 17:33:31.000000000 +0200 >+++ ssp.c 2004-10-16 15:43:54.000000000 +0200 >@@ -76,13 +76,13 @@ > { > int fd; > #ifdef HAVE_DEV_ERANDOM >- if ((fd = open ("/dev/erandom", O_RDONLY)) == (-1)) >+ if ((fd = __open ("/dev/erandom", O_RDONLY)) == (-1)) > #endif >- fd = open ("/dev/urandom", O_RDONLY); >+ fd = __open ("/dev/urandom", O_RDONLY); > if (fd != (-1)) > { >- size = read (fd, (char *) &__guard, sizeof (__guard)); >- close (fd); >+ size = __read (fd, (char *) &__guard, sizeof (__guard)); >+ __close (fd); > if (size == sizeof (__guard)) > return; > } >@@ -97,7 +97,7 @@ > * terminator canary */ > struct timeval tv; > >- gettimeofday (&tv, NULL); >+ __gettimeofday (&tv, NULL); > __guard ^= tv.tv_usec ^ tv.tv_sec; > } > } >@@ -118,52 +118,52 @@ > #endif > > sigset_t mask; >- sigfillset (&mask); >+ __sigfillset (&mask); > >- sigdelset(&mask, SIGABRT); */ /* Block all signal handlers */ >- sigprocmask(SIG_BLOCK, &mask, NULL); */ /* except SIGABRT */ >+ __sigdelset(&mask, SIGABRT); */ /* Block all signal handlers */ >+ __sigprocmask(SIG_BLOCK, &mask, NULL); */ /* except SIGABRT */ > > // sigdelset(&mask, SIGSEGV); /* Block all signal handlers */ > // sigprocmask(SIG_BLOCK, &mask, NULL); /* except SIGSEGV */ > > bufsz = sizeof (buf); >- strcpy (buf, "<2>"); >+ __strcpy (buf, "<2>"); > len = 3; > >- strncat (buf, __progname, sizeof (buf) - 4); >- len = strlen (buf); >+ __strncat (buf, __progname, sizeof (buf) - 4); >+ len = __strlen (buf); > > if (bufsz > len) > { >- strncat (buf, message, bufsz - len - 1); >- len = strlen (buf); >+ __strncat (buf, message, bufsz - len - 1); >+ len = __strlen (buf); > } > if (bufsz > len) > { >- strncat (buf, func, bufsz - len - 1); >- len = strlen (buf); >+ __strncat (buf, func, bufsz - len - 1); >+ len = __strlen (buf); > } > > /* print error message */ > write (STDERR_FILENO, buf + 3, len - 3); > write (STDERR_FILENO, "()\n", 3); > #ifndef __dietlibc__ >- if ((log = socket (AF_UNIX, SOCK_DGRAM, 0)) != -1) >+ if ((log = __socket (AF_UNIX, SOCK_DGRAM, 0)) != -1) > { > /* Send "found" message to the "/dev/log" path */ > sock.sun_family = AF_UNIX; >- (void) strncpy (sock.sun_path, _PATH_LOG, sizeof (sock.sun_path) - 1); >+ (void) __strncpy (sock.sun_path, _PATH_LOG, sizeof (sock.sun_path) - 1); > sock.sun_path[sizeof (sock.sun_path) - 1] = '\0'; >- sendto (log, buf, len, 0, (struct sockaddr *) &sock, sizeof (sock)); >+ __sendto (log, buf, len, 0, (struct sockaddr *) &sock, sizeof (sock)); > } > #endif > /* Make sure the default handler is associated with the our signal handler */ > > memset (&sa, 0, sizeof (struct sigaction)); >- sigfillset (&sa.sa_mask); /* Block all signals */ >+ __sigfillset (&sa.sa_mask); /* Block all signals */ > sa.sa_flags = 0; > sa.sa_handler = SIG_DFL; >- sigaction (SSP_SIGTYPE, &sa, NULL); >- (void) kill (getpid (), SSP_SIGTYPE); >+ __sigaction (SSP_SIGTYPE, &sa, NULL); >+ (void) __kill (__getpid (), SSP_SIGTYPE); > _exit (127); > }
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 65892
:
40757
|
40758
|
41960
|
41964
|
41970
|
49704
|
51578