Imported Upstream version 3.3.0
[debian/amanda] / perl / Amanda / Device.swg
index 479015d38da21ffffc025d1c39cf4cf2766c49b8..e661934ca2e03aab842eb48004d24075a0d072ad 100644 (file)
@@ -31,6 +31,8 @@
 #include "fileheader.h"
 #include "glib-util.h"
 #include "simpleprng.h"
+#include "amanda.h"
+#include "sockaddr-util.h"
 %}
 
 %init %{
@@ -495,6 +497,9 @@ typedef struct Device {
        gboolean
        property_set(DevicePropertyBase *pbase, SV *sv) {
            GValue gval;
+
+           if (!pbase)
+               goto fail;
            memset(&gval, 0, sizeof(gval));
            g_value_init(&gval, pbase->type);
            if (!set_gvalue_from_sv(sv, &gval))