diff options
author | Gerald Combs <gerald@wireshark.org> | 2008-02-15 22:36:24 +0000 |
---|---|---|
committer | Gerald Combs <gerald@wireshark.org> | 2008-02-15 22:36:24 +0000 |
commit | 6537c76fb62d583eb5f98308c15ae31c1712a31a (patch) | |
tree | 8865e9d95e6828e9a2ca528a96d3c7d08ff80943 /epan/uat.c | |
parent | eba80d5c38f495d1943355f8f5a439c1ab3d99d0 (diff) |
Extend the UAT and preferences code so that you can use the "-o" flag
to override UAT entries from the command line, e.g.
-o "uat:user_dlts:\"User 0 (DLT=147)\",\"http\",\"0\",\"\",\"0\",\"\""
Fix up white space.
svn path=/trunk/; revision=24338
Diffstat (limited to 'epan/uat.c')
-rw-r--r-- | epan/uat.c | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/epan/uat.c b/epan/uat.c index 2935a08e0f..e94bb2d9bd 100644 --- a/epan/uat.c +++ b/epan/uat.c @@ -271,6 +271,19 @@ void uat_destroy(uat_t* uat) { } +uat_t *uat_find(gchar *name) { + guint i; + + for (i=0; i < all_uats->len; i++) { + uat_t* u = g_ptr_array_index(all_uats,i); + + if (strcmp(u->name, name) == 0 || strcmp(u->filename, name) == 0) { + return u; + } + } + return NULL; +} + void uat_clear(uat_t* uat) { guint i; @@ -595,3 +608,15 @@ CHK_STR_IS_DEF(isalnum) CHK_STR_IS_DEF(isdigit) CHK_STR_IS_DEF(isxdigit) +/* + * Editor modelines + * + * Local Variables: + * c-basic-offset: 4 + * tab-width: 4 + * indent-tabs-mode: nil + * End: + * + * ex: set shiftwidth=4 tabstop=4 expandtab + * :indentSize=4:tabSize=4:noTabs=true: + */ |