This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
[Bug libc/17477] New: __gconv_get_path crashes if GCONV_PATH set and no current directory
- From: "fweimer at redhat dot com" <sourceware-bugzilla at sourceware dot org>
- To: glibc-bugs at sourceware dot org
- Date: Sat, 11 Oct 2014 09:08:53 +0000
- Subject: [Bug libc/17477] New: __gconv_get_path crashes if GCONV_PATH set and no current directory
- Auto-submitted: auto-generated
https://sourceware.org/bugzilla/show_bug.cgi?id=17477
Bug ID: 17477
Summary: __gconv_get_path crashes if GCONV_PATH set and no
current directory
Product: glibc
Version: 2.20
URL: https://bugzilla.redhat.com/show_bug.cgi?id=1151551
Status: NEW
Severity: normal
Priority: P2
Component: libc
Assignee: unassigned at sourceware dot org
Reporter: fweimer at redhat dot com
CC: drepper.fsp at gmail dot com
Flags: security-
In this piece of code, strlen should only be called if cwd is not NULL:
/* Append the default path to the user-defined path. */
size_t user_len = strlen (__gconv_path_envvar);
gconv_path_len = user_len + 1 + sizeof (default_gconv_path);
gconv_path = alloca (gconv_path_len);
__mempcpy (__mempcpy (__mempcpy (gconv_path, __gconv_path_envvar,
user_len),
":", 1),
default_gconv_path, sizeof (default_gconv_path));
cwd = __getcwd (NULL, 0);
cwdlen = strlen (cwd);
--
You are receiving this mail because:
You are on the CC list for the bug.