HTCondor Project List Archives



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Condor-devel] Bug in condor_dagman?



Dear Folks,
I may have found a bug in condor_dagman. The cmd string below (file dag.C, function Dag::RemoveRunningJobs(), line 1031 in v6_6_8) does not seem to work on Windows due to the way command line quotes are handled.



snprintf( cmd, ARG_MAX, "condor_rm -const \'%s == \"%s\"\'", DAGManJobIdAttrName, DAGManJobId );

The following fix is known to work (note the extra \" in windows part of the code)

#ifndef WIN32
snprintf( cmd, ARG_MAX, "condor_rm -constraint \%c%s == \"%s\"\%c", commandLineQuoteChar,DAGManJobIdAttrName,
DAGManJobId,commandLineQuoteChar);
#else
snprintf( cmd, ARG_MAX, "condor_rm -constraint \%c%s == \"\"%s\"\"\%c", commandLineQuoteChar,DAGManJobIdAttrName,
DAGManJobId,commandLineQuoteChar);
#endif


Thanks,
--
Rajesh Rajamani
Senior Member of Technical Staff
Direct : +1.408.321.9000
Fax    : +1.408.321.9030
Mobile : +1.650.218.9131
raj@xxxxxxxxxx


Optena Corporation 2860 Zanker Road, Suite 201 San Jose, CA 95134 www.optena.com


This electronic transmission (and any attached documents) contains information from Optena Corporation and is for the sole use of the individual or entity it is addressed to. If you receive this message in error, please notify me and destroy the attached message (and all attached documents) immediately.