summaryrefslogtreecommitdiffstats
path: root/Modules
Commit message (Collapse)AuthorAgeFilesLines
* Renamed thread.h to pythread.h.Guido van Rossum1998-10-016-6/+10
|
* Fixes for OS/2 by Jeff Rush.Guido van Rossum1998-09-281-9/+9
|
* Removed some OS/2 #defines (now in the OS/2 specific config.h).Guido van Rossum1998-09-281-15/+0
| | | | Patch by Jeff Rush.
* Get rid of the test for non-NULL thread state in EventHook; it can beGuido van Rossum1998-09-211-2/+0
| | | | triggered in situations that are not an error.
* When we have siginterrupt(), use it to disable restarting interruptedGuido van Rossum1998-09-211-0/+6
| | | | system calls.
* Enable the 'new' module by default.Guido van Rossum1998-09-211-1/+1
|
* Patches from Greg Stein to support 'P' format in struct module'sGuido van Rossum1998-09-181-0/+31
| | | | | native format, as void* (translated to Python int or long). Also adds PyLong_FromVoidPtr and PyLong_AsVoidPtr to longobject.c.
* Remove some unused variables from gethostbyaddr_ex and gethostbyaddr,Guido van Rossum1998-09-131-4/+0
| | | | discovered by Marc Lemburg.
* Michael P. Reilly suggested this fix: makesetup wants to prependGuido van Rossum1998-09-091-0/+1
| | | | "$(srcdir)/" before all source files even when is starts with "/".
* Now that we have standard (optional) long long support, the long longGuido van Rossum1998-08-311-66/+0
| | | | | support in this module can go. The patch only deletes code (PyLong_FromLongLong() and PyLong_AsLongLong()). By Sjoerd Mullender.
* Y2K fix affecting asctime(), mktime(), strftime().Guido van Rossum1998-08-251-19/+37
| | | | | | | | | | | | | | | | 2-digit years are now converted using rules that are (according to Fredrik Lundh) recommended by POSIX or X/Open: 0-68 mean 2000-2068, 69-99 mean 1969-1999. 2-digit years are now only accepted if time.accept2dyear is set to a nonzero integer; if it is zero or not an integer or absent, only year values >= 1900 are accepted. Year values 100-1899 and negative year values are never accepted. The initial value of time.accept2dyear depends on the environment variable PYTHONY2K: if PYTHONY2K is set and non-empty, time.accept2dyear is initialized to 0; if PYTHONY2K is empty or not set, time.accept2dyear is initialized to 0.
* Enter Jim Fulton's latest version. He writes:Jeremy Hylton1998-08-131-20/+80
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | I had to make a slight diddle to work with Python 1.4, which we and some of our customers are still using. :( I've also made a few minor enhancements: - You can now both get and set the memo using a 'memo' attribute. This is handy for certain advanced applications that we have. - Added a 'binary' attribute to get and set the binary mode for a pickler. - Added a somewhat experimental 'fast' attribute. When this is set, objects are not placed in the memo during pickling. This should lead to faster pickling and smaller pickles in cases where: o you *know* there are no circular references, and o either you've: - preloaded the memo with class information by pickling classes in non-fast mode or by manipilating the memo directly, or - aren't pickling instances.
* Need mytime.h for Sleep().Guido van Rossum1998-08-131-0/+2
|
* Two fixes to find_class:Jeremy Hylton1998-08-111-9/+22
| | | | | | | | | | | | | | | 1. Only DECREF the class's module when the module is retrieved via PyImport_Import. If it is retrieved from the modules dictionary with PyDict_GetItem, it is using a borrowed reference. 2. If the module doesn't define the desired class, raise the same SystemError that pickle.py does instead of returning an AttributeError (which is cryptic at best). Also, fix the PyArg_ParseTuple in cpm_loads (the externally visible loads) function: Use "S" instead of "O" because cStringIO will croak with a "bad arguments to internal function" if passed anything other than a string.
* Added a module docstring (that's all this module needs).Guido van Rossum1998-08-111-1/+15
|
* Now include Python.hGuido van Rossum1998-08-081-0/+2
|
* Jim Fulton's patches to get rid of the class_map().Guido van Rossum1998-08-081-73/+27
|
* In Win32 version of listdir(), when FindFirstFile() returnsGuido van Rossum1998-08-061-0/+2
| | | | | ERROR_FILE_NOT_FOUND, return an empty list instead of raising an exception.
* Removed unused variables.Guido van Rossum1998-08-061-4/+0
|
* Undo a silly effect of a global substitution: the macintosh panic()Guido van Rossum1998-08-051-1/+1
| | | | | function had a reference to vPySys_WriteStderr(...) -- turn it back into fprintf(stder, ...).
* Changes for BeOS, QNX and long long, by Chris Herborth.Guido van Rossum1998-08-0412-14/+132
|
* Added gethostbyname_ex(), which returns the same kind of data asGuido van Rossum1998-08-041-37/+99
| | | | | | | | gethostbyaddr(). (Plain gethostbyname() returns only the IP address.) This moves the code shared by gethostbyaddr() and gethostbyname_ex() to a subroutine. Original patch by Dan Stromberg; some tweaks by GvR.
* parser__pickler(): Use Py_DECREF() when reference is known to be non-NULL.Fred Drake1998-08-041-1/+1
|
* Patch by Jody Winston (with my changes) to add some of the "waitGuido van Rossum1998-08-041-0/+151
| | | | | status inspection" macros as functions: WEXITSTATUS(), WIFEXITED(), WIFSIGNALED(), WIFSTOPPED(), WSTOPSIG(), WTERMSIG().
* Better error messages when raising ValueError for int literals. (TheGuido van Rossum1998-08-041-8/+3
| | | | | previous version of this code would not show the offending input, even though there was code that attempted this.)
* Make sure that at least one digit has been consumed in atoi().Guido van Rossum1998-07-251-0/+4
|
* Use 'S' format character for the optional constructor argument, so weGuido van Rossum1998-07-241-1/+1
| | | | | get a decent error message when it's not a string (instead of confusing errors when trying to use the thing).
* Several changes to support inclusion of filename in releventBarry Warsaw1998-07-231-13/+21
| | | | | | | | | | | | | | | | | | | | | exceptions: posix_error_with_filename(): New function which calls PyErr_SetFromErrnoWithFilename() The following methods have been changed to call posix_error_with_filename(): posix_1str() posix_strint() posix_strintint() posix_do_stat() posix_mkdir() posix_utime() posix_readlink() posix_open() INITFUNC(): os.error (nee PosixError) is PyExc_OSError
* (pause_doc): Sun CC complains about newline in string literalBarry Warsaw1998-07-211-2/+2
|
* Add test for failure of the getattr call in pcre_expand() -- it usedGuido van Rossum1998-07-171-0/+4
| | | | to core dump if the first argument did not have a "group" attribute.
* I_getattr(),Fred Drake1998-07-171-1/+7
| | | | | O_getattr(): Added read-only access to the closed attribute, based on comment from Michael Scharf <Michael.Scharf@Rhein-Neckar.de>.
* Temporarily get rid of the registration of Tcl_Finalize() as aGuido van Rossum1998-07-141-0/+5
| | | | | | | | | low-level Python exit handler. This can attempt to call Python code at a point that the interpreter and thread state have already been destroyed, causing a Bus Error. Given the intended use of Py_AtExit(), I'm not convinced that it's a good idea to call it earlier during Python's finalization sequence... (Although this is the only use for it in the entire distribution.)
* Marc-Andre Lemburg's patch to support instance methods with otherGuido van Rossum1998-07-081-3/+15
| | | | callable objects than regular Pythonm functions as their im_func.
* Add a cast that a picky SGI compiler found was necessary.Guido van Rossum1998-07-071-1/+1
|
* Fix a benign problem found by a picky SGI compiler (unreachable breakGuido van Rossum1998-07-071-1/+0
| | | | after a return).
* Fix benign problems found by a picky SGI compiler (unreachable breakGuido van Rossum1998-07-071-2/+0
| | | | after a return or goto).
* Fix benign problems found by a picky SGI compiler (unreachable breakGuido van Rossum1998-07-072-20/+0
| | | | after a return).
* Fix some problems that a picky SGI compiler reported. Two were benignGuido van Rossum1998-07-071-3/+1
| | | | | (unreachable break after a return) but one was a real bug: ReadFrames() was getting a bogus framecount because of a missing '&'.
* Added copious docstrings, plus two minor layout tweaks.Guido van Rossum1998-07-071-39/+309
|
* On Windows, put the select file descriptor arrays on the heap.Guido van Rossum1998-07-021-0/+22
| | | | | This is because they are huge and the stack is limited on Windows. Other platforms keep declaring it on the stack.
* Unsigned 1 and 2 byte sized formats shouldn't result in long integer values!Guido van Rossum1998-06-291-2/+8
|
* # Added missing semicolon (was #ifdef'ed out in edit on Windows).Guido van Rossum1998-06-281-1/+1
|
* Added doc strings.Guido van Rossum1998-06-282-10/+98
|
* Added doc strings.Guido van Rossum1998-06-271-11/+114
|
* # Remove an extra blank line from a doc string.Guido van Rossum1998-06-271-1/+0
|
* Added doc strings. Also export LockType from the modoule, and give itGuido van Rossum1998-06-271-15/+102
| | | | a doc string.
* Added <ctype.h>, needed for Windows.Guido van Rossum1998-06-191-0/+1
|
* There was an error check in a loop in PythonCmd which calledGuido van Rossum1998-06-191-1/+1
| | | | | | | PythonCmd_Error() but failed to return. The error wasn't very likely (only when we run out of memory) but since the check is there we might as well return the error. (I think that Barry introduced this buglet when he added error checks everywhere.)
* # Note: a previous checkin message was lost because I can now use CVSGuido van Rossum1998-06-151-36/+7
| | | | | | | | | # from my PC at home, but it can't send email :-( Add a clarifying comment about the new ENTER_OVERLAP and LEAVE_OVERLAP_TCL macros; get rid of all the bogus tests for deleted interpreters (Tcl already tests for this; they were left over from an earlier misguided attempt to fix the threading).
* # (My first checkin from Windows NT using remote CVS!)Guido van Rossum1998-06-151-52/+134
| | | | | | | | | | | | | | | | | | | | There were some serious problem with the thread-safety code. The basic problem was that often the result was gotten out of the Tcl interpreter object after releasing the Tcl lock. Of course, another thread might have changed the return value already, and this was indeed happening. (Amazing what trying it on a different thread implementation does!) The solution is to grab the Python lock without releasing the Tcl lock, so it's safe to create a string object or set the exceptions from the Tcl interpreter. Once that's done, the Tcl lock is released. Note that it's now legal to acquire the Python lock while the the Tcl lock is held; but the reverse is not true: the Python lock must be released before the Tcl lock is acquired. This in order to avoid deadlines. Fortunately, there don't seem to be any problems with this.