]> git.sur5r.net Git - bacula/bacula/commitdiff
- Fix non-python prototypes in dummy routines.
authorKern Sibbald <kern@sibbald.com>
Wed, 1 Dec 2004 09:19:11 +0000 (09:19 +0000)
committerKern Sibbald <kern@sibbald.com>
Wed, 1 Dec 2004 09:19:11 +0000 (09:19 +0000)
- Add python 2.3 to config search list (user submitted patch)
- Add JobStatus to Python variables.

git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/trunk@1734 91ce42f0-d328-0410-95d8-f526ca767f89

bacula/src/dird/python.c
bacula/src/lib/util.c
bacula/src/version.h

index bda706e664c3e10b5fa79278ceb7e19ccd69ece9..d539bd4fa6162a135230c987b78b0d0ab3a5c3e2 100644 (file)
@@ -67,6 +67,7 @@ static struct s_vars vars[] = {
    { N_("Catalog"),    "s"},
    { N_("MediaType"),  "s"},
    { N_("JobName"),    "s"},
+   { N_("JobStatus"),  "s"},
    
    { NULL,            NULL}
 };
@@ -79,6 +80,7 @@ PyObject *bacula_get(PyObject *self, PyObject *args)
    char *item;
    bool found = false;
    int i;
+   char buf[10];
 
    if (!PyArg_ParseTuple(args, "Os:get", &CObject, &item)) {
       return NULL;
@@ -118,6 +120,10 @@ PyObject *bacula_get(PyObject *self, PyObject *args)
       return Py_BuildValue(vars[i].fmt, jcr->store->media_type);
    case 11:                          /* JobName */
       return Py_BuildValue(vars[i].fmt, jcr->Job);
+   case 12:                          /* JobStatus */
+      buf[1] = 0;
+      buf[0] = jcr->JobStatus;
+      return Py_BuildValue(vars[i].fmt, buf);
    }
    return NULL;
 }
index 32f9d0afabfcec6d95b068c836477e819c469531..b2c499aadb9aade883ce364288dca6ac5a509060 100644 (file)
@@ -547,9 +547,6 @@ POOLMEM *edit_job_codes(JCR *jcr, char *omsg, char *imsg, const char *to)
            } else {
                str = "*none*";
            }
-           if (!str) {
-               str = "";
-           }
            break;
          case 'd':
             str = my_name;            /* Director's name */
index 6d5067be97802ab98647eed29f6c267ec0023d02..10d0c573da5f291ec565c2f38e583161827b848a 100644 (file)
@@ -1,8 +1,8 @@
 /* */
 #undef  VERSION
 #define VERSION "1.37.1"
-#define BDATE   "29 November 2004"
-#define LSMDATE "29Nov04"
+#define BDATE   "01 December 2004"
+#define LSMDATE "01Dec04"
 
 /* Debug flags */
 #undef  DEBUG