Commit Graph

49 Commits

Author SHA1 Message Date
Thomas Wouters 6dbff33be8 SF bug/patch #1433877: string parameter to ioctl not null terminated
The new char-array used in ioctl calls wasn't explicitly NUL-terminated;
quite probably the cause for the test_pty failures on Solaris that we
circumvented earlier. (I wasn't able to reproduce it with this patch, but it
has been somewhat elusive to start with.)
2006-04-25 13:53:23 +00:00
Thomas Wouters 857b300b2e Explain why we use the unsigned int format for a signed int variable.
(Should 'code' be cast to the right pointer type?)
2006-03-02 17:58:27 +00:00
Thomas Wouters 26cc63f867 Make Py_ssize_t-clean 2006-03-02 00:21:10 +00:00
Neal Norwitz 1ac754fa10 Check return result from Py_InitModule*(). This API can fail.
Probably should be backported.
2006-01-19 06:09:39 +00:00
Hye-Shik Chang 97bb8ad394 Fix a typo. (found by Jong-uk Kim) 2005-07-28 05:57:19 +00:00
Michael W. Hudson 8137bea4ca This is barry-scott's patch:
[ 1231069 ] ioctl has problem with -ive request codes

by using the 'I' not the 'i' format code to PyArg_ParseTuple().

Backport candidate?  Maybe...
2005-07-27 20:24:40 +00:00
Michael W. Hudson 02d74f68c6 Hear the #error: change the default value of the mutable_arg argument
to ioctl() and remove the warning when it is not supplied.
2004-11-30 14:31:54 +00:00
Martin v. Löwis 77ca6c4c84 Warn abou missing mutate flag to ioctl. Fixes #696535. 2004-06-03 12:47:26 +00:00
Neal Norwitz 4730880d76 Fix typo, refer to proper argument name 2003-06-30 01:54:04 +00:00
Michael W. Hudson 505c4c2858 Simple fix for
[ 733781 ] fcntl fails to build on old RH Linux
2003-05-09 10:45:20 +00:00
Martin v. Löwis c16f3bd8a3 Patch #708495: Port more stuff to OpenVMS. 2003-05-03 09:14:54 +00:00
Michael W. Hudson f008998668 Fix bug
[ 555817 ] Flawed fcntl.ioctl implementation.

with my patch that allows for an array to be mutated when passed
as the buffer argument to ioctl() (details complicated by
backwards compatibility considerations -- read the docs!).
2003-03-03 12:29:42 +00:00
Martin v. Löwis 14e73b1864 Expose I_ constants. Auto-detect stropts.h. Properly configure the slave terminal. 2003-01-01 09:51:12 +00:00
Mark Hammond fe51c6d66e Excise DL_EXPORT/DL_IMPORT from Modules/*. Required adding a prototype
for Py_Main().

Thanks to Kalle Svensson and Skip Montanaro for the patches.
2002-08-02 02:27:13 +00:00
Martin v. Löwis 14f8b4cfcb Patch #568124: Add doc string macros. 2002-06-13 20:33:02 +00:00
Andrew MacIntyre 7bf6833e17 OS/2 EMX port changes (Modules part of patch #450267):
Modules/
    _hotshot.c
    dbmmodule.c
    fcntlmodule.c
    main.c
    pwdmodule.c
    readline.c
    selectmodule.c
    signalmodule.c
    termios.c
    timemodule.c
    unicodedata.c
2002-03-03 02:59:16 +00:00
Martin v. Löwis cdc4451222 Include <unistd.h> in Python.h. Fixes #500924. 2002-01-12 11:05:12 +00:00
Martin v. Löwis 1baeba6839 Add fcntl.h constants from glibc 2.2.4. Fixes #496171. 2001-12-28 21:08:12 +00:00
Fred Drake 460f0691df fcntl.ioctl(): Update error message; necessity noted by Michael Hudson. 2001-05-14 21:02:36 +00:00
Fred Drake 1d531997a6 Fix the fcntl() docstring so the user is not mis-directed to the FCNTL
module for useful constants.
2001-05-10 15:54:32 +00:00
Fred Drake 152a25ee1c Modify to allow file objects wherever file descriptors are needed.
This closes SF bug #231328.

Added all constants needed to use the functions defined in this module
that are not defined elsewhere (the O_* symbols are available in the
os module).  No additonal modules are needed to use this now.
2001-05-09 21:02:02 +00:00
Sjoerd Mullender 82e00d6350 Let's keep things portable to non GCC compilers, please.
You can only use mult-line strings in C if each line ends in \.
2001-01-25 10:10:39 +00:00
Barry Warsaw bd3dc1f0cb lockf_doc: a much better description of the lockf() function, based on
an eyeballing of the code.
2001-01-25 00:20:13 +00:00
Guido van Rossum 8586991099 REMOVED all CWI, CNRI and BeOpen copyright markings.
This should match the situation in the 1.6b1 tree.
2000-09-01 23:29:29 +00:00
Barry Warsaw 9bfd2bf5ed Do the absolute minimal amount of modifications to eradicate
Py_FatalError() from module initialization functions.  The importing
mechanism already checks for PyErr_Occurred() after module importation
and it Does The Right Thing.

Unfortunately, the following either were not compiled or tested by the
regression suite, due to issues with my development platform:

	almodule.c
	cdmodule.c
	mpzmodule.c
	puremodule.c
	timingmodule.c
2000-09-01 09:01:32 +00:00
Guido van Rossum a2214c37fd Rob Hooft (Patch #101046): use PyArg_ParseTuple everywhere. 2000-08-02 20:46:51 +00:00
Thomas Wouters f3f33dcf03 Bunch of minor ANSIfications: 'void initfunc()' -> 'void initfunc(void)',
and a couple of functions that were missed in the previous batches. Not
terribly tested, but very carefully scrutinized, three times.

All these were found by the little findkrc.py that I posted to python-dev,
which means there might be more lurking. Cases such as this:

long
func(a, b)
	long a;
	long b; /* flagword */
{

and other cases where the last ; in the argument list isn't followed by a
newline and an opening curly bracket. Regexps to catch all are welcome, of
course ;)
2000-07-21 06:00:07 +00:00
Peter Schneider-Kamp 8bc8f0d036 ANSI-fication 2000-07-10 17:15:07 +00:00
Guido van Rossum ffcc3813d8 Change copyright notice - 2nd try. 2000-06-30 23:58:06 +00:00
Guido van Rossum fd71b9e9d4 Change copyright notice. 2000-06-30 23:50:40 +00:00
Guido van Rossum 43713e5a28 Massive patch by Skip Montanaro to add ":name" to as many
PyArg_ParseTuple() format string arguments as possible.
2000-02-29 13:59:29 +00:00
Guido van Rossum 056bad993c Changes for long file support by Steve Clift.
He also fixes thread-related evil that caused core dumps.
1999-01-06 18:44:23 +00:00
Guido van Rossum 3886bb6997 Add DL_EXPORT() to all modules that could possibly be used
on BeOS or Windows.
1998-12-04 18:50:17 +00:00
Guido van Rossum 185ead6f37 Doc strings by Chris Petrilli. 1998-11-23 15:32:55 +00:00
Guido van Rossum 7c14103d77 Keep gcc -Wall happy 1997-08-15 02:52:08 +00:00
Guido van Rossum f4e32c729b Add definitions for symbolic constants LOCK_{EX,NB,SH,UN}. 1997-07-31 19:39:54 +00:00
Roger E. Masse 4ca4b07516 Opps, left in a /*#include "modsupport.h"*/ 1996-12-17 17:46:28 +00:00
Roger E. Masse 919213a098 Grandly renamed. 1996-12-17 17:42:22 +00:00
Guido van Rossum 3d65fa3488 Include <sys/ioctl.h>, to keep gcc -Wall happy. 1996-12-09 18:49:14 +00:00
Guido van Rossum a376cc5cc8 Keep gcc -Wall happy. 1996-12-05 23:43:35 +00:00
Guido van Rossum d266eb460e New permission notice, includes CNRI. 1996-10-25 14:44:06 +00:00
Guido van Rossum c864364395 Added lockf() call 1996-09-11 23:17:20 +00:00
Guido van Rossum 3c0b79ca0f A fcntl implementation for systems (like Solaris) without flock() call.
By Sjoerd.
1996-06-11 15:11:34 +00:00
Guido van Rossum 3539b1e919 Added flock(). 1996-05-23 22:56:38 +00:00
Guido van Rossum 903f487684 add BGN/END_SAVE macros around fcntl/ioctl calls 1995-10-07 19:18:22 +00:00
Guido van Rossum 524b588553 Added 1995 to copyright message.
Setup.in: clarified Tk comments somewhat.
structmodule.c: use memcpy() instead of double precision assignment.
1995-01-04 19:10:35 +00:00
Guido van Rossum b6775db241 Merge alpha100 branch back to main trunk 1994-08-01 11:34:53 +00:00
Guido van Rossum 9bfef44d97 * Changed all copyright messages to include 1993.
* Stubs for faster implementation of local variables (not yet finished)
* Added function name to code object.  Print it for code and function
  objects.  THIS MAKES THE .PYC FILE FORMAT INCOMPATIBLE (the version
  number has changed accordingly)
* Print address of self for built-in methods
* New internal functions getattro and setattro (getattr/setattr with
  string object arg)
* Replaced "dictobject" with more powerful "mappingobject"
* New per-type functio tp_hash to implement arbitrary object hashing,
  and hashobject() to interface to it
* Added built-in functions hash(v) and hasattr(v, 'name')
* classobject: made some functions static that accidentally weren't;
  added __hash__ special instance method to implement hash()
* Added proper comparison for built-in methods and functions
1993-03-29 10:43:31 +00:00
Guido van Rossum 0297512a08 struct: pack/unpack binary structs; fcntl: fcntl(), ioctl(). 1992-08-17 08:55:12 +00:00