svn commit: trunk/uClibc/libc/sysdeps/linux/common
aldot at uclibc.org
aldot at uclibc.org
Tue Dec 16 15:40:16 UTC 2008
Author: aldot
Date: 2008-12-16 07:40:15 -0800 (Tue, 16 Dec 2008)
New Revision: 24432
Log:
- emulate unavailable syscall getpgrp on e.g. ia64 (Stefan Assmann)
Modified:
trunk/uClibc/libc/sysdeps/linux/common/getpgrp.c
Changeset:
Modified: trunk/uClibc/libc/sysdeps/linux/common/getpgrp.c
===================================================================
--- trunk/uClibc/libc/sysdeps/linux/common/getpgrp.c 2008-12-16 13:55:57 UTC (rev 24431)
+++ trunk/uClibc/libc/sysdeps/linux/common/getpgrp.c 2008-12-16 15:40:15 UTC (rev 24432)
@@ -2,7 +2,7 @@
/*
* getpgrp() for uClibc
*
- * Copyright (C) 2000-2006 by Erik Andersen <andersen at codepoet.org>
+ * Copyright (C) 2000-2008 by Erik Andersen <andersen at codepoet.org>
*
* Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
*/
@@ -13,4 +13,16 @@
#ifdef __NR_getpgrp
/* According to the manpage the POSIX.1 version is favoured */
_syscall0(pid_t, getpgrp)
+#elif defined __NR_getpgid && (defined __NR_getpid || defined __NR_getxpid)
+/* IA64 doesn't have a getpgrp syscall */
+pid_t getpgrp(void)
+{
+ return getpgid(getpid());
+}
+#elif defined __UCLIBC_HAS_STUBS__
+pid_t getpgrp(void)
+{
+ __set_errno(ENOSYS);
+ return -1;
+}
#endif
More information about the uClibc-cvs
mailing list