aboutsummaryrefslogtreecommitdiffstats
path: root/epan/value_string.h
diff options
context:
space:
mode:
authorBill Meier <wmeier@newsguy.com>2013-12-13 14:39:19 +0000
committerBill Meier <wmeier@newsguy.com>2013-12-13 14:39:19 +0000
commit099efcf5eb7252a8bc87197a652dd5f2f5e0cbd5 (patch)
tree1e45b133bdff12b4b7c51098bab341486c636bf3 /epan/value_string.h
parentaa08f7bab1598e3265532e6b5c2fb2e4c1c29bf6 (diff)
Value_string.h: Minor changes to comment text
value_string.c: value_string_ext_validate() always fails on Windows when called from a different DLL (i.e. a plugin). So: Add #ifndef _WIN32 around the offending code. svn path=/trunk/; revision=54047
Diffstat (limited to 'epan/value_string.h')
-rw-r--r--epan/value_string.h32
1 files changed, 16 insertions, 16 deletions
diff --git a/epan/value_string.h b/epan/value_string.h
index c83aa73b24..1e2c6713b4 100644
--- a/epan/value_string.h
+++ b/epan/value_string.h
@@ -40,7 +40,7 @@ typedef struct _value_string {
} value_string;
#if 0
- /*--- VALUE_STRING "Helper" macros */
+ /* ----- VALUE_STRING "Helper" macros ----- */
/* Essentially: Provide the capability to define a list of value_strings once and
then to expand the list as an enum and/or as a value_string array. */
@@ -49,11 +49,11 @@ typedef struct _value_string {
/*- define list of value strings -*/
#define foo_VALUE_STRING_LIST(XXX) \
- XXX( foo_a, 1, "aaa" ) \
- XXX( foo_b, 3, "bbb" )
+ XXX( FOO_A, 1, "aaa" ) \
+ XXX( FOO_B, 3, "bbb" )
/*- gen enum -*/
- VALUE_STRING_ENUM(foo); /* gen's 'enum {foo_a=1, foo_b=3};' */
+ VALUE_STRING_ENUM(foo); /* gen's 'enum {FOO_A=1, FOO_B=3};' */
/*- gen value_string array -*/
/* local */
@@ -65,11 +65,11 @@ typedef struct _value_string {
/* Alternatively: */
#define bar_VALUE_STRING_LIST(XXX) \
- XXX( bar_a, 1) \
- XXX( bar_b, 3)
+ XXX( BAR_A, 1) \
+ XXX( BAR_B, 3)
- VALUE_STRING_ENUM2(bar); /* gen's 'enum {bar_a=1, bar_b=3};' */
- VALUE_STRING_ARRAY2(bar); /* gen's 'static const value_string bar[] = {{1,"bar_a"}, {3,"bar_b"}}; */
+ VALUE_STRING_ENUM2(bar); /* gen's 'enum {BAR_A=1, BAR_B=3};' */
+ VALUE_STRING_ARRAY2(bar); /* gen's 'static const value_string bar[] = {{1,"BAR_A"}, {3,"BAR_B"}}; */
...
#endif
@@ -161,19 +161,19 @@ typedef const value_string *(*_value_string_match2_t)(const guint32, const struc
typedef struct _value_string_ext {
_value_string_match2_t _vs_match2;
- guint32 _vs_first_value; /* first value of the value_string array */
- guint _vs_num_entries; /* number of entries in the value_string array */
- /* (excluding final {0, NULL}) */
- const value_string *_vs_p; /* the value string array address */
- const gchar *_vs_name; /* vse "Name" (for error messages) */
+ guint32 _vs_first_value; /* first value of the value_string array */
+ guint _vs_num_entries; /* number of entries in the value_string array */
+ /* (excluding final {0, NULL}) */
+ const value_string *_vs_p; /* the value string array address */
+ const gchar *_vs_name; /* vse "Name" (for error messages) */
} value_string_ext;
-#define VALUE_STRING_EXT_VS_P(x) (x)->_vs_p
+#define VALUE_STRING_EXT_VS_P(x) (x)->_vs_p
#define VALUE_STRING_EXT_VS_NUM_ENTRIES(x) (x)->_vs_num_entries
-#define VALUE_STRING_EXT_VS_NAME(x) (x)->_vs_name
+#define VALUE_STRING_EXT_VS_NAME(x) (x)->_vs_name
WS_DLL_PUBLIC
-const value_string*
+const value_string *
_try_val_to_str_ext_init(const guint32 val, const value_string_ext *vse);
#define VALUE_STRING_EXT_INIT(x) { _try_val_to_str_ext_init, 0, G_N_ELEMENTS(x)-1, x, #x }