Make sure the keysym list is present before allocating a buffer to hold
[obnox/wireshark/wip.git] / packet-dcerpc-remact.c
index abfd82a6173dc7b5ffaa7981f7018acc47c097a7..2967c65c9252708446ef4ccad6de4a7ad7117a4b 100644 (file)
@@ -2,7 +2,7 @@
  * Routines for DCOM Remote Activation
  * Copyright 2001, Todd Sabin <tas@webspan.net>
  *
- * $Id: packet-dcerpc-remact.c,v 1.3 2002/01/21 07:36:33 guy Exp $
+ * $Id: packet-dcerpc-remact.c,v 1.8 2003/08/04 02:49:02 tpot Exp $
  *
  * Ethereal - Network traffic analyzer
  * By Gerald Combs <gerald@ethereal.com>
 #endif
 
 
-#ifdef HAVE_SYS_TYPES_H
-#include <sys/types.h>
-#endif
-
 #include <string.h>
 
 #include <glib.h>
@@ -41,6 +37,8 @@
 
 static int proto_remact = -1;
 
+static int hf_opnum = -1;
+
 static gint ett_remact = -1;
 
 
@@ -57,18 +55,17 @@ static dcerpc_sub_dissector remact_dissectors[] = {
 void
 proto_register_remact (void)
 {
-#if 0
        static hf_register_info hf[] = {
+               { &hf_opnum,
+                 { "Operation", "remact.opnum", FT_UINT16, BASE_DEC,
+                   NULL, 0x0, "", HFILL }},
        };
-#endif
 
        static gint *ett[] = {
-               &ett_remact,
+               &ett_remact
        };
        proto_remact = proto_register_protocol ("DCOM Remote Activation", "REMACT", "remact");
-#if 0
        proto_register_field_array (proto_remact, hf, array_length (hf));
-#endif
        proto_register_subtree_array (ett, array_length (ett));
 }
 
@@ -76,5 +73,5 @@ void
 proto_reg_handoff_remact (void)
 {
        /* Register the protocol as dcerpc */
-       dcerpc_init_uuid (proto_remact, ett_remact, &uuid_remact, ver_remact, remact_dissectors);
+       dcerpc_init_uuid (proto_remact, ett_remact, &uuid_remact, ver_remact, remact_dissectors, hf_opnum);
 }