mirror of
https://sourceware.org/git/glibc.git
synced 2024-12-23 03:10:05 +00:00
glob: Silence warning about void pointer arithmetic
Sync with gnulib 0e14f025d2. Checked on x86_64-linux-gnu. * lib/glob.c (glob): Use a 'char *', not a 'void *', in pointer arithmetic. Signed-off-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
This commit is contained in:
parent
d711a00f93
commit
e184ac3a10
@ -1,5 +1,8 @@
|
||||
2017-12-19 Adhemerval Zanella <adhemerval.zanella@linaro.org>
|
||||
|
||||
* lib/glob.c (glob): Use a 'char *', not a 'void *', in pointer
|
||||
arithmetic.
|
||||
|
||||
* lib/glob.c (glob): Do not pass NULL to mempcpy.
|
||||
|
||||
2017-12-19 Joseph Myers <joseph@codesourcery.com>
|
||||
|
@ -641,7 +641,8 @@ __glob (const char *pattern, int flags, int (*errfunc) (const char *, int),
|
||||
{
|
||||
# if defined HAVE_GETPWNAM_R || defined _LIBC
|
||||
size_t ssize = strlen (s.data) + 1;
|
||||
err = getpwnam_r (s.data, &pwbuf, s.data + ssize,
|
||||
char *sdata = s.data;
|
||||
err = getpwnam_r (sdata, &pwbuf, sdata + ssize,
|
||||
s.length - ssize, &p);
|
||||
# else
|
||||
p = getpwnam (s.data);
|
||||
|
Loading…
Reference in New Issue
Block a user