[Python-checkins] python/dist/src/Modules posixmodule.c,2.235,2.236
loewis@users.sourceforge.net
loewis@users.sourceforge.net
Thu, 13 Jun 2002 14:09:14 -0700
- Previous message: [Python-checkins] python/dist/src/Modules _hotshot.c,1.17,1.18 _localemodule.c,2.31,2.32 _ssl.c,1.3,1.4 _weakref.c,1.15,1.16 almodule.c,1.35,1.36 arraymodule.c,2.73,2.74 binascii.c,2.33,2.34 cPickle.c,2.84,2.85 cStringIO.c,2.35,2.36 cmathmodule.c,2.29,2.30 cryptmodule.c,2.12,2.13 errnomodule.c,2.16,2.17 fcntlmodule.c,2.34,2.35 gcmodule.c,2.43,2.44 gdbmmodule.c,2.32,2.33 grpmodule.c,2.17,2.18 mathmodule.c,2.67,2.68 md5module.c,2.29,2.30 newmodule.c,2.38,2.39 operator.c,2.20,2.21 parsermodule.c,2.69,2.70 posixmodule.c,2.234,2.235 pwdmodule.c,1.33,1.34 pyexpat.c,2.59,2.60 readline.c,2.50,2.51 resource.c,2.25,2.26 selectmodule.c,2.63,2.64 shamodule.c,2.18,2.19 signalmodule.c,2.67,2.68 socketmodule.c,1.227,1.228 stropmodule.c,2.88,2.89 structmodule.c,2.54,2.55 termios.c,2.34,2.35 threadmodule.c,2.49,2.50 timemodule.c,2.126,2.127 unicodedata.c,2.17,2.18 xreadlinesmodule.c,1.9,1.10 xxsubtype.c,2.14,2.15 zlibmodule.c,2.61,2.62
- Next message: [Python-checkins] python/dist/src/RISCOS pyconfig.h,1.3,1.4
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Update of /cvsroot/python/python/dist/src/Modules
In directory usw-pr-cvs1:/tmp/cvs-serv30598/Modules
Modified Files:
posixmodule.c
Log Message:
Patch #568235: Add posix.setpgid.
Index: posixmodule.c
===================================================================
RCS file: /cvsroot/python/python/dist/src/Modules/posixmodule.c,v
retrieving revision 2.235
retrieving revision 2.236
diff -C2 -d -r2.235 -r2.236
*** posixmodule.c 13 Jun 2002 20:32:50 -0000 2.235
--- posixmodule.c 13 Jun 2002 21:09:08 -0000 2.236
***************
*** 2118,2121 ****
--- 2118,2140 ----
#endif
+ #ifdef HAVE_GETPGID
+ static char posix_getpgid__doc__[] =
+ "getpgid(pid) -> pgid\n\
+ Call the system call getpgid().";
+
+ static PyObject *
+ posix_getpgid(PyObject *self, PyObject *args)
+ {
+ int pid, pgid;
+ if (!PyArg_ParseTuple(args, "i:getpgid", &pid))
+ return NULL;
+ pgid = getpgid(pid);
+ if (pgid < 0)
+ return posix_error();
+ return PyInt_FromLong((long)pgid);
+ }
+ #endif /* HAVE_GETPGID */
+
+
#ifdef HAVE_GETPGRP
PyDoc_STRVAR(posix_getpgrp__doc__,
***************
*** 6407,6410 ****
--- 6426,6432 ----
{"setgroups", posix_setgroups, METH_VARARGS, posix_setgroups__doc__},
#endif /* HAVE_SETGROUPS */
+ #ifdef HAVE_GETPGID
+ {"getpgid", posix_getpgid, METH_VARARGS, posix_getpgid__doc__},
+ #endif /* HAVE_GETPGID */
#ifdef HAVE_SETPGRP
{"setpgrp", posix_setpgrp, METH_VARARGS, posix_setpgrp__doc__},
- Previous message: [Python-checkins] python/dist/src/Modules _hotshot.c,1.17,1.18 _localemodule.c,2.31,2.32 _ssl.c,1.3,1.4 _weakref.c,1.15,1.16 almodule.c,1.35,1.36 arraymodule.c,2.73,2.74 binascii.c,2.33,2.34 cPickle.c,2.84,2.85 cStringIO.c,2.35,2.36 cmathmodule.c,2.29,2.30 cryptmodule.c,2.12,2.13 errnomodule.c,2.16,2.17 fcntlmodule.c,2.34,2.35 gcmodule.c,2.43,2.44 gdbmmodule.c,2.32,2.33 grpmodule.c,2.17,2.18 mathmodule.c,2.67,2.68 md5module.c,2.29,2.30 newmodule.c,2.38,2.39 operator.c,2.20,2.21 parsermodule.c,2.69,2.70 posixmodule.c,2.234,2.235 pwdmodule.c,1.33,1.34 pyexpat.c,2.59,2.60 readline.c,2.50,2.51 resource.c,2.25,2.26 selectmodule.c,2.63,2.64 shamodule.c,2.18,2.19 signalmodule.c,2.67,2.68 socketmodule.c,1.227,1.228 stropmodule.c,2.88,2.89 structmodule.c,2.54,2.55 termios.c,2.34,2.35 threadmodule.c,2.49,2.50 timemodule.c,2.126,2.127 unicodedata.c,2.17,2.18 xreadlinesmodule.c,1.9,1.10 xxsubtype.c,2.14,2.15 zlibmodule.c,2.61,2.62
- Next message: [Python-checkins] python/dist/src/RISCOS pyconfig.h,1.3,1.4
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]