Fred Drake [Wed, 27 Sep 2000 22:43:54 +0000 (22:43 +0000)]
Allow spaces in section names.
Do not expose the __name__ when reporting the list of options available
for a section since that is for internal use.
This closes SourceForge bug #115357.
Additionally, define InterpolationDepthError and MAX_INTERPOLATION_DEPTH.
The exception is raised by get*() when value interpolation cannot be
completed within the defined recursion limit. The constant is only
informative; changing it will not affect the allowed depth.
Fix the exit from get() so that None is not returned if the depth is met
or exceeded; either return the value of raise InterpolationDepthError.
Jeremy Hylton [Wed, 27 Sep 2000 20:51:17 +0000 (20:51 +0000)]
Fix buffer overflow vulnerabilities in calculate_path(). Code used
copied strings from environment variables and argv[0] into
fixed-length buffers without checking their length.
Reported by Stan Bubrouski; advice on fix from John Viega.
Added a section describing the new development process. Part of it
comes from two comp.lang.tcl postings of mine, with much rewriting
and expansion of the material.
Note that 2.0 will be released in the autumn, not the summer.
Remove deprecation warnings on old 'link_*()' methods, ie. they're not
deprecated after all. But now they're only implemented once, instead
of N times.
Big patch from Rene Liebscher to simplify the CCompiler API and
implementations. Details:
* replace 'link_shared_object()', 'link_shared_lib()', and
'link_executable()' with 'link()', which is (roughly)
the union of the three methods it replaces
* in all implementation classes (UnixCCompiler, MSVCCompiler, etc.),
ditch the old 'link_*()' methods and replace them with 'link()'
* in the abstract base class (CCompiler), add the old 'link_*()'
methods as wrappers around the new 'link()' (they also print
a warning of the deprecated interface)
Also increases consistency between MSVCCompiler and BCPPCompiler,
hopefully to make it easier to factor out the mythical WindowsCCompiler
class. Details:
* use 'self.linker' instead of 'self.link'
* add ability to compile resource files to BCPPCompiler
* added (redundant?) 'object_filename()' method to BCPPCompiler
* only generate a .def file if 'export_symbols' defined
Fred Drake [Tue, 26 Sep 2000 17:23:09 +0000 (17:23 +0000)]
Fix handling of file inputs on Windows; passing them to urllib.urlopen()
caused the drive letter to cause urlopen() to think it was an unrecognized
URL scheme. This only passes system ids to urlopen() if the file does not
exist. It works on Windows & Unix.
Fixed some typos, added some punctuation (e.g. consistently terminate
sentences with a period and put () after function/method names), and
filled in the blanks on mailbox and posixfile. Noted <limits.h> change.
Fred Drake [Tue, 26 Sep 2000 05:46:01 +0000 (05:46 +0000)]
Rationalize use of limits.h, moving the inclusion to Python.h.
Add definitions of INT_MAX and LONG_MAX to pyport.h.
Remove includes of limits.h and conditional definitions of INT_MAX
and LONG_MAX elsewhere.
This closes SourceForge patch #101659 and bug #115323.
Tim Peters [Mon, 25 Sep 2000 21:55:28 +0000 (21:55 +0000)]
Bump Windows "build number" to 6.
Note that somebody still needs to change the interpreter to say "2.0b2";
I'm assuming that's a normal part of somebody's Unix release checklist.
Tim Peters [Mon, 25 Sep 2000 21:01:28 +0000 (21:01 +0000)]
Replace SIGFPE paranoia around strtod and atof. I don't believe these
fncs are allowed to raise SIGFPE (see the C std), but OK by me if
people using --with-fpectl want to pay for checking anyway.
Fred Drake [Mon, 25 Sep 2000 17:23:04 +0000 (17:23 +0000)]
Add obsolescence note to the module descriptions that get added to the
list of module synopses at the front of the chapter; based on a comment
from Aahz <aahz@panix.com>.
Jeremy Hylton [Mon, 25 Sep 2000 17:00:24 +0000 (17:00 +0000)]
fix bug #114290: when interpreter's argv[0] has a relative path make
it absolute by joining it with getcwd result. avoid including
unnecessary ./ in path but do not test for ../ (more complicated)
Barry Warsaw [Mon, 25 Sep 2000 15:08:27 +0000 (15:08 +0000)]
AddrlistClass.getdomainliteral(): rfc822 requires that the domain
literal be wrapped in square brackets. This fix replaces the square
brackets that were previously being stripped off. Closes SF bug
#110621.
When reading the file, option names were not passed through
self.optionxform(), which (in the default case) caused options spelled
with opper case letters in their name to be inaccessible. Reported by
"Todd R. Palmer" <t2palmer@bellsouth.net> on
activepython@listserv1.ActiveState.com.
For the benefit of SunOS 4.1.4, define MS_SYNC as 0 when it's
undefined. ccording to MvL, this is safe: the MS_SYNC flag means that
msync() returns when all I/O operations are scheduled; without it, it
waits until they are complete, which is acceptable behavior.
Fredrik Lundh [Mon, 25 Sep 2000 08:07:06 +0000 (08:07 +0000)]
unicode database compression, step 2:
- fixed attributions
- moved decomposition data to a separate table, in preparation
for step 3 (which won't happen before 2.0 final, promise!)
- use relative paths in the generator script
I have a lot more stuff in the works for 2.1, but let's leave
that for another day...
Tim Peters [Mon, 25 Sep 2000 07:13:41 +0000 (07:13 +0000)]
Fiddled w/ /F's cool new splitbins function: documented it, generalized it
a bit, sped it a lot primarily by removing the unused assumption that None was
a legit bin entry (the function doesn't really need to assume that there's
anything special about 0), added an optional "trace" argument, and in __debug__
mode added exhaustive verification that the decomposition is both correct and
doesn't overstep any array bounds (which wasn't obvious to me from staring at the
generated C code -- now I feel safe!). Did not commit a new unicodedata_db.h, as
the one produced by this version is identical to the one already checked in.
Added a bunch of missing "=" signs in the option table.
Removed script options -- don't think they ever worked, weren't
very well thought through, etc.
Fixed some bugs and mis-features in handling config files:
* options can now be spelled "foo-bar" or "foo_bar" (handled in
'parse_config_files()', just after we parse a file)
* added a "[global]" section so there's a place to set global
options like verbose/quiet and dry-run
* respect the "negative alias" dictionary so (eg.) "quiet=1" is
the same as "verbose=0" (this had to be done twice: once in
'parse_config_file()' for global options, and once in
'_set_command_options()' for per-command options)
* the other half of handling boolean options correctly: allow
commands to list their boolean options in a 'boolean_options'
class attribute, and use it to translate strings (like "yes", "1",
"no", "0", etc) to true or false
Jack Jansen [Sun, 24 Sep 2000 22:00:11 +0000 (22:00 +0000)]
Handle the ****/**** appleevent wildcard when called as a main program, so that it becomes a handy debugging tool (BuildApplet, copy aete resource, apply applescript to it).
Jack Jansen [Sun, 24 Sep 2000 21:56:43 +0000 (21:56 +0000)]
Added a workaround for shortcomings in the OSA support: there can be class/property conflicts and passing classes as arguments doesn't work. The package now seems to work.
Martin v. Löwis [Sun, 24 Sep 2000 21:31:06 +0000 (21:31 +0000)]
[Patch 101634]
xml.sax: Fix parse and parseString not to rely on ExpatParser
Greatly simplify import logic by using __import__
saxutils: Support Unicode strings and files as parameters to
prepare_input_source
Martin v. Löwis [Sun, 24 Sep 2000 19:40:25 +0000 (19:40 +0000)]
If dbopen is not in libc, checking whether it is in libdb will fail if
db_185.h has renamed that function to __db185_open, which it does in DB 3.1.
So don't check whether the function is in -ldb.
Fredrik Lundh [Sun, 24 Sep 2000 18:51:25 +0000 (18:51 +0000)]
- Improved handling of win32 proxy settings (addresses bug #114256).
The earlier code assumed "protocol=host;protocol=host;..." or "host",
but Windows may also use "protocol=host" (just one entry), as well as
"protocol://host". This code needs some more work, so I'll leave the
bug open for now.