[drmaa-wg] Re: Patch to python DRMAA wrapper for thread usage

Andreas Haas Andreas.Haas at Sun.COM
Wed Apr 12 07:31:58 CDT 2006


On Wed, 12 Apr 2006 enrico.sirola at riskmap.it wrote:

> Another change I made is allocating space for the string vector
> input arguments (e.g. for passing environments to job templates),
> because not doing so leaded to interpreter crash. Do the functions
> accepting string vector inputs properly deallocate space? If the
> client has the responsibility of deallocating space then now we have
> a memory leak (which is not so bad, except for long-running tasks),
> so let me know what's the precise behaviour (or point me to
> the specs page so I can set up a workaround).

There might be a memory leak in the Python binding, if it assumes
memory gets deallocated automatically. The functions for memory
deallocation are:

   int drmaa_delete_job_template(drmaa_job_template_t *jt,
               char *error_diagnosis, size_t error_diag_len);
   void drmaa_release_attr_names(drmaa_attr_names_t* values);
   void drmaa_release_attr_values(drmaa_attr_values_t* values);
   void drmaa_release_job_ids(drmaa_job_ids_t* values);

Cheers,
Andreas





More information about the drmaa-wg mailing list