OK - no attachments through the mailing list.... Huh. I'll send it to Michiel directly.
-- Tom Jordahl Macromedia -----Original Message----- From: Tom Jordahl [mailto:[EMAIL PROTECTED]] Sent: Wednesday, October 31, 2001 10:34 AM To: CF-Linux Subject: RE: cfml crashes with command-line argument Yikes! This is a bug that has been around for quite a while. Attached is a fixed version for Linux. I also fixed up some other places where putenv was used with stack buffers. BTW - did you know you can add Query string arguments to the cfml command line? Like this: ./cfml /docroot/foo.cfm arg1 arg2 arg3 Thanks for the good analysis! -- Tom Jordahl Macromedia -----Original Message----- From: Michiel Boland [mailto:[EMAIL PROTECTED]] Sent: Wednesday, October 31, 2001 3:56 AM To: CF-Linux Subject: cfml crashses with command-line argument Hi. Using ColdFusion 5 on RedHat 7.2. I am trying to invoke /opt/coldfusion/webserver/cgi/cfml to invoke ColdFusion pages from the command line and from my mathopd web server. I simply do this:- /opt/coldfusion/webserver/cgi/cfml /var/www/html/test.cfm This crashes every time I try it. If I do not specify a command line argument but rely on the good old template= query string hack things work. But that is not what I want. It appears that the following occurs inside cfml (obtained through gdb) The cfml program checks for either argv[1] or PATH_TRANSLATED (in that order) and if one of them is defined and not empty it will call putenv() to create a new environment variable CF_TEMPLATE_PATH with the value of argv[1] or PATH_TRANSLATED, respectively. Unfortunately some other function, RequestContextInit() overwrites the memory storage for CF_TEMPLATE_PATH with zero bytes which causes a crash later on. Is this a known bug? I would love to get this to work. CF5 on Solaris does not have this problem, by the way, but that may just be a coincidence. Cheers Michiel ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Get the mailserver that powers this list at http://www.coolfusion.com ------------------------------------------------------------------------------ Archives: http://www.mail-archive.com/cf-linux%40houseoffusion.com/ To Unsubscribe visit http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_linux or send a message to [EMAIL PROTECTED] with 'unsubscribe' in the body.
