Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 347200 Details for
Bug 468354
media-sound/alsa-utils-1.0.27 buffer overflow in alsactl
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
reserve enough space for sprintf()
fix-buffer-overflow.patch (text/plain), 689 bytes, created by
Alex Turbov
on 2013-05-03 06:00:09 UTC
(
hide
)
Description:
reserve enough space for sprintf()
Filename:
MIME Type:
Creator:
Alex Turbov
Created:
2013-05-03 06:00:09 UTC
Size:
689 bytes
patch
obsolete
>diff -ub -r alsa-utils-1.0.27.org/alsactl/lock.c alsa-utils-1.0.27/alsactl/lock.c >--- alsa-utils-1.0.27.org/alsactl/lock.c 2013-04-11 15:43:06.000000000 +0400 >+++ alsa-utils-1.0.27/alsactl/lock.c 2013-05-03 09:49:45.000000000 +0400 >@@ -35,7 +35,7 @@ > int fd = -1, err = 0; > struct flock lck; > struct stat st; >- char lcktxt[11]; >+ char lcktxt[20]; > char *nfile; > > if (!do_lock) >@@ -53,6 +53,8 @@ > lck.l_len = 11; > lck.l_pid = 0; > if (lock) { >+ // NOTE `long` type on amd64, being printed, could take up to 18 decimal digits >+ // (according output of std::numeric_limits<long>::digits10) > sprintf(lcktxt, "%10li\n", (long)getpid()); > } else { > sprintf(lcktxt, "%10s\n", "");
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 468354
: 347200