Thanks for the patch, applied in

http://pywin32.hg.sourceforge.net/hgweb/pywin32/pywin32/rev/fcfbe0ff52ca

    Roger

From: Chris Clark 
Sent: Wednesday, December 03, 2014 7:08 PM
To: rup...@spideroak.com 
Cc: python-win32@python.org 
Subject: win32api - small patch for win32verstamp.py

I found an hgweb repo for win32api at 
http://pywin32.hg.sourceforge.net/hgweb/pywin32/pywin32 but I could not work 
out how to clone it (I even tried the usual Mercurial path for sf projects, 
http://hg.code.sf.net/p/pywin32/mercurial ) so please excuse the inline diff. 
rupole, your name was on the last commit hence emailing you!

 

I’ve updated win32/Lib/win32verstamp.py to allow empty values for original 
filename. The previous test was a negative test, if original value is not 
specified this is set to None, if a user explicitly sets an empty string this 
will now be used instead of being overwritten and ignored.

 

 

C:\ >diff -u C:\Python27\Lib\site-packages\win32\lib\win32verstamp.py 
win32verstamp.py

--- C:\Python27\Lib\site-packages\win32\lib\win32verstamp.py    Sat Mar 19 02:51

:22 2011

+++ win32verstamp.py    Wed Dec 03 16:03:16 2014

@@ -1,3 +1,5 @@

+# based on Python27\Lib\site-packages\win32\lib\win32verstamp.py

+# original filename now supports empty strings

""" Stamp a Win32 binary with version information.

"""

 

@@ -126,7 +128,7 @@

   if not ifn:

     ifn = os.path.basename(pathname)

   ofn = options.original_filename

-  if not ofn:

+  if ofn is None:

     ofn = os.path.basename(pathname)

 

   sdata = {

 

I have previously signed a PSF contributor agreement 
https://www.python.org/psf/contrib/ a while back if that helps any.

 

Regards,

 

Chris

 
_______________________________________________
python-win32 mailing list
python-win32@python.org
https://mail.python.org/mailman/listinfo/python-win32

Reply via email to