Hurd: fix mode type for openat
This commit is contained in:
parent
918d4d7163
commit
61f06bd3ba
@ -1,5 +1,8 @@
|
|||||||
2012-05-10 Samuel Thibault <samuel.thibault@ens-lyon.org>
|
2012-05-10 Samuel Thibault <samuel.thibault@ens-lyon.org>
|
||||||
|
|
||||||
|
* sysdeps/mach/hurd/openat.c (__openat): Set type of MODE to mode_t
|
||||||
|
instead of int.
|
||||||
|
|
||||||
* sysdeps/mach/hurd/xmknodat.c (__xmknodat): Deallocate NODE port only
|
* sysdeps/mach/hurd/xmknodat.c (__xmknodat): Deallocate NODE port only
|
||||||
if __dir_mkfile succeeded.
|
if __dir_mkfile succeeded.
|
||||||
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* openat -- Open a file named relative to an open directory. Hurd version.
|
/* openat -- Open a file named relative to an open directory. Hurd version.
|
||||||
Copyright (C) 2006 Free Software Foundation, Inc.
|
Copyright (C) 2006-2012 Free Software Foundation, Inc.
|
||||||
This file is part of the GNU C Library.
|
This file is part of the GNU C Library.
|
||||||
|
|
||||||
The GNU C Library is free software; you can redistribute it and/or
|
The GNU C Library is free software; you can redistribute it and/or
|
||||||
@ -34,14 +34,14 @@ __openat (fd, file, oflag)
|
|||||||
const char *file;
|
const char *file;
|
||||||
int oflag;
|
int oflag;
|
||||||
{
|
{
|
||||||
int mode;
|
mode_t mode;
|
||||||
io_t port;
|
io_t port;
|
||||||
|
|
||||||
if (oflag & O_CREAT)
|
if (oflag & O_CREAT)
|
||||||
{
|
{
|
||||||
va_list arg;
|
va_list arg;
|
||||||
va_start (arg, oflag);
|
va_start (arg, oflag);
|
||||||
mode = va_arg (arg, int);
|
mode = va_arg (arg, mode_t);
|
||||||
va_end (arg);
|
va_end (arg);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
Loading…
x
Reference in New Issue
Block a user