aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/wimaxasncp
diff options
context:
space:
mode:
authorGerald Combs <gerald@wireshark.org>2007-10-12 18:26:47 +0000
committerGerald Combs <gerald@wireshark.org>2007-10-12 18:26:47 +0000
commitff5826a106d55bb58ca0f56adc081784609f3874 (patch)
tree15ebb968f261b0b2b0e7291d17e04ae089238cbb /plugins/wimaxasncp
parent13bf6bc269bf21f7d199afd7564277877d0aa9f3 (diff)
Fix wimaxasncp compilation under Windows. Rename a macro that's defined
by the platform SDK, cast an int, and use the top-level Makefile.nmake.inc to build wimaxasncp_dict.{c|obj}. svn path=/trunk/; revision=23165
Diffstat (limited to 'plugins/wimaxasncp')
-rw-r--r--plugins/wimaxasncp/Makefile.nmake10
-rw-r--r--plugins/wimaxasncp/wimaxasncp_dict.l6
2 files changed, 7 insertions, 9 deletions
diff --git a/plugins/wimaxasncp/Makefile.nmake b/plugins/wimaxasncp/Makefile.nmake
index 6e4d3ebce6..2fdae31fcd 100644
--- a/plugins/wimaxasncp/Makefile.nmake
+++ b/plugins/wimaxasncp/Makefile.nmake
@@ -6,6 +6,7 @@
include ..\..\config.nmake
include moduleinfo.nmake
+include ..\..\Makefile.nmake.inc
include Makefile.common
@@ -90,13 +91,10 @@ plugin.c: $(DISSECTOR_SRC) ../../tools/make-dissector-reg.py ../../tools/make-di
!ENDIF
-RUNLEX=..\..\tools\runlex.sh
+RUNLEX = ..\..\tools\runlex.sh
-wimaxasncp.obj : wimaxasncp_dict.c
-wimaxasncp_dict_lex.h: wimaxasncp_dict.c
-
-wimaxasncp_dict.c: wimaxasncp_dict.l
- $(RUNLEX) -o wimaxasncp_dict.c wimaxasncp_dict.l
+wimaxasncp_dict_lex.h : wimaxasncp_dict.c
+wimaxasncp_dict.obj : wimaxasncp_dict.c
clean:
rm -f $(OBJECTS) $(RESOURCE) plugin.c *.pdb \
diff --git a/plugins/wimaxasncp/wimaxasncp_dict.l b/plugins/wimaxasncp/wimaxasncp_dict.l
index 8b08d5b54b..3be6a524ee 100644
--- a/plugins/wimaxasncp/wimaxasncp_dict.l
+++ b/plugins/wimaxasncp/wimaxasncp_dict.l
@@ -83,7 +83,7 @@ typedef struct entity_t {
#define ATTR_UINT16(cont) do { D(("attr_uint16 " #cont "\t" )); attr_uint16 = &(cont); yy_push_state(GET_UINT16_ATTR); } while(0)
#define ATTR_STR(cont) do { D(("attr_str " #cont "\t" )); attr_str = &(cont); yy_push_state(GET_ATTR); } while(0)
#define ATTR_DECODER(cont) do { D(("attr_decoder " #cont "\t" )); attr_uint = &(cont); yy_push_state(GET_DECODER_ATTR); } while(0)
-#define IGNORE() do { D(("ignore: %s\t",yytext)); yy_push_state(IGNORE_ATTR); } while(0)
+#define WIMAXASNCP_IGNORE() do { D(("ignore: %s\t",yytext)); yy_push_state(IGNORE_ATTR); } while(0)
#define D(args) wimaxasncp_dict_debug args
@@ -322,7 +322,7 @@ decoder_attr decoder=\042
}
<GET_UINT16_ATTR>{number} {
- *attr_uint16 = strtol(yytext,NULL,0);
+ *attr_uint16 = (gint16) strtol(yytext,NULL,0);
D(("%s\n",yytext););
attr_uint16 = NULL;
BEGIN END_ATTR;
@@ -431,7 +431,7 @@ decoder_attr decoder=\042
yyterminate();
}
-<TLV_ATTRS,ENUM_ATTRS>{ignored_attr} IGNORE();
+<TLV_ATTRS,ENUM_ATTRS>{ignored_attr} WIMAXASNCP_IGNORE();
<OUTSIDE>. ;