]> git.ipfire.org Git - thirdparty/dhcp.git/commitdiff
Fix a coredump when adding a class via OMAPI [rt17162]
authorEvan Hunt <each@isc.org>
Tue, 6 May 2008 22:59:51 +0000 (22:59 +0000)
committerEvan Hunt <each@isc.org>
Tue, 6 May 2008 22:59:51 +0000 (22:59 +0000)
RELNOTES
server/omapi.c

index cc70b8667aa513947553adef60b80da079cac9e6..c48e36f97bcaf516caa4227ac35095a6cb9d7051 100644 (file)
--- a/RELNOTES
+++ b/RELNOTES
@@ -50,6 +50,8 @@ work on other platforms. Please report any problems and suggested fixes to
 
                        Changes since 4.1.0a1
 
+- Fixed a coredump when adding a class via OMAPI.
+
 - Check whether files are zero length before trying to parse them.
 
 - Ari Edelkind's PARANOIA patch has been included and may be compiled in
index 4420e81dc74f48c9cc0704ec90f311c7c87a9d52..4cc5a6895f6dcde32a232db6d318b0b2d3e65136 100644 (file)
@@ -1869,11 +1869,10 @@ class_set_value (omapi_object_t *h,
                        if (!strncmp("hardware",
                                     (char *)value->u.buffer.value, minlen))
                        {
-                               if (!expression_allocate(&class->submatch,
-                                                        MDL))
+                               if (!expression_allocate(&class->submatch, MDL))
                                        return ISC_R_NOMEMORY;
 
-                               class->expr->op = expr_hardware;
+                               class->submatch->op = expr_hardware;
                        } else
                                return ISC_R_INVALIDARG;
                } else