]> git.sur5r.net Git - bacula/bacula/blobdiff - bacula/src/stored/pythonsd.c
Make cd accept wildcards
[bacula/bacula] / bacula / src / stored / pythonsd.c
index e52693d8233b4ed18b6c182a800b78856fe4bf3b..978cc656d8d6844d75d6add5e08e0b1b2b2d8c12 100644 (file)
@@ -1,12 +1,12 @@
 /*
    Bacula® - The Network Backup Solution
 
-   Copyright (C) 2005-2008 Free Software Foundation Europe e.V.
+   Copyright (C) 2005-2011 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.
    This program is Free Software; you can redistribute it and/or
-   modify it under the terms of version two of the GNU General Public
+   modify it under the terms of version three of the GNU Affero General Public
    License as published by the Free Software Foundation and included
    in the file LICENSE.
 
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
    General Public License for more details.
 
-   You should have received a copy of the GNU General Public License
+   You should have received a copy of the GNU Affero General Public License
    along with this program; if not, write to the Free Software
    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
    02110-1301, USA.
 
-   Bacula® is a registered trademark of John Walker.
+   Bacula® is a registered trademark of Kern Sibbald.
    The licensor of Bacula is the Free Software Foundation Europe
    (FSFE), Fiduciary Program, Sumatrastrasse 25, 8006 Zürich,
    Switzerland, email:ftf@fsfeurope.org.
@@ -31,7 +31,7 @@
  *
  * Kern Sibbald, January MMV
  *
- *   Version $Id$
+ *  SD Python interface removed 17 December 2011 (KES)
  *
  */
 
 #include "bacula.h"
 #include "stored.h"
 
-#ifdef HAVE_PYTHON
+#ifdef xxxxHAVE_PYTHON
 #undef _POSIX_C_SOURCE
 #include <Python.h>
 
-extern JCR *get_jcr_from_PyObject(PyObject *self);
-extern PyObject *find_method(PyObject *eventsObject, PyObject *method, 
-         const char *name);
+#include <lib/pythonlib.h>
 
 static PyObject *set_job_events(PyObject *self, PyObject *arg);
 static PyObject *job_write(PyObject *self, PyObject *arg);
@@ -120,9 +118,9 @@ PyObject *job_getattr(PyObject *self, char *attrname)
    case 1:                            /* SD's name */
       return Py_BuildValue((char *)getvars[i].fmt, my_name);
    case 2:                            /* level */
-      return Py_BuildValue((char *)getvars[i].fmt, job_level_to_str(jcr->JobLevel));
+      return Py_BuildValue((char *)getvars[i].fmt, job_level_to_str(jcr->getJobLevel()));
    case 3:                            /* type */
-      return Py_BuildValue((char *)getvars[i].fmt, job_type_to_str(jcr->JobType));
+      return Py_BuildValue((char *)getvars[i].fmt, job_type_to_str(jcr->getJobType()));
    case 4:                            /* JobId */
       return Py_BuildValue((char *)getvars[i].fmt, jcr->JobId);
    case 5:                            /* Client */
@@ -281,4 +279,4 @@ int generate_job_event(JCR *jcr, const char *event)
 { return 1; }
 
 
-#endif /* HAVE_PYTHON */
+#endif /* xxxxHAVE_PYTHON */