Bug 169253

Summary: Python segfaults on startup with no arguments
Product: [Fedora] Fedora Reporter: Ivan Gyurdiev <ivg231>
Component: pythonAssignee: Mihai Ibanescu <mihai.ibanescu>
Status: CLOSED RAWHIDE QA Contact: Brock Organ <borgan>
Severity: medium Docs Contact:
Priority: medium    
Version: rawhideCC: dmalcolm, katzj
Target Milestone: ---   
Target Release: ---   
Hardware: i386   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2005-09-27 14:07:28 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Ivan Gyurdiev 2005-09-26 08:23:03 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8b4) Gecko/20050915 Fedora/1.5-0.5.0.beta1 Firefox/1.4

Description of problem:
Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread -1209203024 (LWP 13039)]
0x007bc9f3 in PySys_SetArgv () from /usr/lib/libpython2.4.so.1.0
(gdb) bt
#0  0x007bc9f3 in PySys_SetArgv () from /usr/lib/libpython2.4.so.1.0
#1  0x007bfdad in Py_Main () from /usr/lib/libpython2.4.so.1.0
#2  0x0804859a in main ()


Version-Release number of selected component (if applicable):
python-2.4.1-10

How reproducible:
Always

Steps to Reproduce:
1. Run python with no arguments.

Additional info:

Comment 1 Dave Malcolm 2005-09-26 23:24:40 UTC
I'm seeing this too, same version: python-2.4.1-10

Running python scripts seems to work.

(gdb) bt
#0  0x003899f3 in PySys_SetArgv (argc=1, argv=0xbfe396c8) at Python/sysmodule.c:1192
#1  0x0038cdad in Py_Main (argc=0, argv=0xbfe396c4) at Modules/main.c:459
#2  0x0804859a in main (argc=1, argv=0xbfe396c4) at Modules/python.c:23

#ifdef HAVE_CANONICALIZE_FILE_NAME
1190			int errnum;
1191	                
1192	                if (argv[0][0] == '\0') 

(gdb) print argv
$18 = (char **) 0xbfe396c8
(gdb) print argv[0]
$19 = 0x0
(gdb) print argv[0][0]
Cannot access memory at address 0x0

Comment 2 Dave Malcolm 2005-09-26 23:28:13 UTC
Seems to be fixed in python-2.4.1-13

Comment 3 Peter Jones 2005-09-27 14:07:28 UTC
Fixed in rawhide, closing.