Re: python commmand line params from c++
Available news archives: comp.lang.tcl - comp.lang.python - comp.security.firewalls - sci.crypt - comp.lang.php - comp.lang.javascript
Google
 
Web news.hping.org


comp.lang.python archive

Re: python commmand line params from c++

From: Wesley Henwood <wesleyhenwood@hotmail.com>
Date: Thu Jun 30 2005 - 21:16:08 CEST

Thanks Denis. PySys_SetArgv should do the trick. The nested function
calls are there because the FILE structrure produced by fopen is not
always compatible with the FILE structure produced by the Python C++
functions. Something do with the Python C being built with different
version ofthe c run-time libs.

The problem is a bit strange and should be adressed, it's documented
somewhere on the Python site, but no solution is given. That I had to
find by trial and error. Even better would be a function such as
PyRun_File(char *filename), and do away with handling the FILE
structure altogether.
Received on Thu Sep 29 16:40:26 2005