80 Commits

Author SHA1 Message Date
Andrew M. Kuchling
e7031223e3 [Backport of rev. 42093 by neal.norwitz]
Check return result from Py_InitModule*().  This API can fail.

Probably should be backported.
2006-09-27 19:17:32 +00:00
Andrew M. Kuchling
4c16bac18c [Backport of rev. 51683 by neal.norwitz]
Bug #1548092: fix curses.tparm seg fault on invalid input.  Needs
backport to 2.5.1 and earlier.
2006-09-27 19:04:53 +00:00
Andrew M. Kuchling
124696aa9f [Backport rev.51254 from neal.norwitz]
Handle failure from PyModule_GetDict() (Klocwork 208).

Fix a bunch of refleaks in the init of the module.  This would only be found
when running python -v.
2006-09-27 19:02:02 +00:00
Andrew M. Kuchling
34749f7328 [Bug #1471938] Fix build problem on Solaris 8 by conditionalizing the use of mvwgetnstr(); it was conditionalized a few lines below. Fix from Paul Eggert. I also tried out the STRICT_SYSV_CURSES case and am therefore removing the 'untested' comment. 2006-07-26 17:25:53 +00:00
Neal Norwitz
44d52e2393 Backport:
SF bug #1400822, Extended version of _curses over{lay,write} does not work

Fix signatures to conform to doc (also fixed ungetmouse()).
2006-01-10 07:08:06 +00:00
Andrew M. Kuchling
5672467b2d Fix check for error condition 2005-06-15 18:48:16 +00:00
Andrew M. Kuchling
44416678ac [Bug #1200134] Fix buffer overflow by constraining size of .getstr(), .instr() to size of allocated buffer 2005-06-09 17:55:34 +00:00
Michael W. Hudson
7d6cc5b303 Fix a leak of a reference on None. 2004-08-04 14:33:28 +00:00
Andrew M. Kuchling
69f31eb80c [Patch #739124] Add use_default_colors() to curses module 2003-08-13 23:11:04 +00:00
Michael W. Hudson
2100798b8c Always call tparm with 10 arguments. It seems it's not varargs i
more often than it is.  In response to bug:

[ 641808 ] Portability of Modules/_cursesmodule.c

submitted by Nick Mclaren.
2002-11-21 14:17:51 +00:00
Andrew M. Kuchling
7e23f00948 [Patch #633635 from David M. Cooke]
Make keyname raise ValueError if passed -1, avoiding a segfault
   Make getkey() match the docs and raise an exception in nodelay mode
   The return type of getch() is int, not chtype
2002-11-06 14:15:36 +00:00
Andrew M. Kuchling
3adefccdcb Use personal e-mail address 2002-10-30 21:08:34 +00:00
Martin v. Löwis
c9d07dfc87 Remove duplicate definitions of _XOPEN_SOURCE_EXTENDED. 2002-10-26 13:36:13 +00:00
Martin v. Löwis
21ee4091e1 Patch #615069: Fix build problems on SCO Open Server 5. Backported to 2.2. 2002-09-30 16:19:48 +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
Michael W. Hudson
67fb0c3705 I think this fixes
[ #510644 ] test_curses segfaults

If we use the *object* *allocator*, we should use the *object* *deallocator*,
not the *raw memory* deallocator (confused yet?).

I think this was what caused segfaults when pymalloc was enabled.

Even if it wasn't the cause, it's still wrong.

2.2.1 candidate.
2002-01-30 15:39:28 +00:00
Martin v. Löwis
c0e1671c71 Patch #477752: Drop old-style getargs from curses. 2002-01-17 23:08:27 +00:00
Michael W. Hudson
8f5146088a Change some spaces to tabs. I don't *think* that was me, but it
might have been...
2002-01-16 15:18:09 +00:00
Michael W. Hudson
f24281251f Fix for
[ #504284 ] Last build problems on AIX

I'm ignoring the suggestion that this should be an autoconf test in the
interests of having a fix today.  Feel free to quibble.
2002-01-16 15:14:49 +00:00
Guido van Rossum
146483964e Patch supplied by Burton Radons for his own SF bug #487390: Modifying
type.__module__ behavior.

This adds the module name and a dot in front of the type name in every
type object initializer, except for built-in types (and those that
already had this).  Note that it touches lots of Mac modules -- I have
no way to test these but the changes look right.  Apologies if they're
not.  This also touches the weakref docs, which contains a sample type
object initializer.  It also touches the mmap test output, because the
mmap type's repr is included in that output.  It touches object.h to
put the correct description in a comment.
2001-12-08 18:02:58 +00:00
Martin v. Löwis
43f2dc6251 Limit string size on one-character-strings. Fixes #480384. 2001-11-11 14:49:15 +00:00
Martin v. Löwis
00ff10cae4 Patch in bug report #477700: Fix memory leaks in gdbm & curses. 2001-11-11 14:24:05 +00:00
Martin v. Löwis
eb9b103296 Check for HP/UX curses problems. Define _XOPEN_SOURCE_EXTENDED and
STRICT_SYSV_CURSES when compiling curses module on HP/UX. Generalize
access to _flags on systems where WINDOW is opaque. Fixes bugs
#432497, #422265, and the curses parts of #467145 and #473150.
2001-10-24 17:10:49 +00:00
Andrew M. Kuchling
16e65a023e Add two forgotten 'break' statements
Allow passing strings to the .border() method
Correct some error messages ("1 or 4" -> "1 to 4")
Bump version number
Tweak code formatting
Update my e-mail address
2001-10-20 16:05:52 +00:00
Martin v. Löwis
1c07b4b4fb Test for __sun instead of __sun__, since SUNWspro only defines the latter;
gcc defines both.
2001-10-13 09:00:42 +00:00