[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: [PATCH] Issue 990: SWIG Python on Win32

From: Russell Yanofsky <rey4_at_columbia.edu>
Date: 2003-02-26 21:02:14 CET

Dale Hirt wrote:
> [...]
>
> This is the problem. apr_time_t is a 64-bit integer. All sorts of
> nasty things are happening here. Long is not big enough, and MSVC
> 6.0 doesn't recognize long long. We need a solution that will work.

Well this change was really just a shot in the dark to fix a runtime error,
"TypeError: Type error. Expected _p_time_t", that occured in cvs2svn when
util.apr_time_ansi_put() was called.

I think the reason it worked is the function takes a time_t parameter
instead of an apr_time_t one. apr_time_t might be 64 bits, but time_t is
only 32 bits.

>> tools/cvs2svn/cvs2svn.py:
>> * Opens RCS files in binary mode instead of text mode to prevent
>> CRLF -> LF substitution on windows.
>> * Leaves out buffer size argument to os.popen() to
>> prevent runtime
>> error on windows with python 2.2.1
>
> Can we change this based on the os? Do we absolutely need the buffer
> argument on other OS's? I'm more inclined to pass it in based on the
> os, instead of just blankly omitting it.
>

Me too. I was just afraid of breaking the script or hurting its performance
on unix. I suspect the problem with os.popen is a python library bug and not
a platform issue because you do specify a buffer size in win32 when you
create pipes. The error I got under activestate python 2.2.1 with the
original statement is "ValueError: popen() arg 3 must be -1"

- Russ

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Feb 26 21:03:36 2003

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.