]> git.sur5r.net Git - bacula/bacula/blobdiff - bacula/src/dird/pythondir.c
Ensure that StorageId is updated after write
[bacula/bacula] / bacula / src / dird / pythondir.c
index e3e8fb7d3e51bfdbb39f16716099108be09d634f..1782e7fae401e01d26698c081117b7fac8b11c0a 100644 (file)
@@ -1,7 +1,7 @@
 /*
    Bacula® - The Network Backup Solution
 
-   Copyright (C) 2004-2008 Free Software Foundation Europe e.V.
+   Copyright (C) 2004-2012 Free Software Foundation Europe e.V.
 
    The main author of Bacula is Kern Sibbald, with contributions from
    many others, a complete list can be found in the file AUTHORS.
@@ -31,7 +31,6 @@
  *
  * Kern Sibbald, November MMIV
  *
- *   Version $Id$
  *
  */
 
@@ -294,7 +293,7 @@ int job_setattr(PyObject *self, char *attrname, PyObject *value)
          for (i=0; joblevels[i].level_name; i++) {
             if (strcmp(strval, joblevels[i].level_name) == 0) {
                if (joblevels[i].job_type == jcr->getJobType()) {
-                  jcr->set_JobLevel(joblevels[i].level);
+                  jcr->setJobLevel(joblevels[i].level);
                   jcr->jr.JobLevel = jcr->getJobLevel();
                   return 0;
                }
@@ -382,7 +381,6 @@ static PyObject *job_does_vol_exist(PyObject *self, PyObject *args)
       MEDIA_DBR mr;
       int ok;
       JCR *jcr = get_jcr_from_PyObject(self);
-      memset(&mr, 0, sizeof(mr));
       bstrncpy(mr.VolumeName, VolName, sizeof(mr.VolumeName));
       ok = db_get_media_record(jcr, jcr->db, &mr);
       return Py_BuildValue("i", ok);