aboutsummaryrefslogtreecommitdiffstats
path: root/epan/tvbuff.c
diff options
context:
space:
mode:
authorJeff Morriss <jeff.morriss@ulticom.com>2010-10-30 18:53:31 +0000
committerJeff Morriss <jeff.morriss@ulticom.com>2010-10-30 18:53:31 +0000
commit0b7e2cd37e4ab9b508567981a3bb66495b201552 (patch)
treecf26eecdea002c27f3a6e5ba731fbb6d789555b7 /epan/tvbuff.c
parentaf3d0b2bde774c26cd36d9fbb3574927a7943405 (diff)
Make tvb_strncaseeql()'s size parameter be a size_t. Cast the size to int before calling ensure_contiguous_no_exception() (also in tvb_strneql()).
svn path=/trunk/; revision=34727
Diffstat (limited to 'epan/tvbuff.c')
-rw-r--r--epan/tvbuff.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/epan/tvbuff.c b/epan/tvbuff.c
index d2ee540faf..f1003dcb5e 100644
--- a/epan/tvbuff.c
+++ b/epan/tvbuff.c
@@ -1986,7 +1986,7 @@ tvb_strneql(tvbuff_t *tvb, const gint offset, const gchar *str, const size_t siz
{
const guint8 *ptr;
- ptr = ensure_contiguous_no_exception(tvb, offset, size, NULL);
+ ptr = ensure_contiguous_no_exception(tvb, offset, (gint)size, NULL);
if (ptr) {
int cmp = strncmp((const char *)ptr, str, size);
@@ -2009,11 +2009,11 @@ tvb_strneql(tvbuff_t *tvb, const gint offset, const gchar *str, const size_t siz
* 0 if it returns 0 (meaning "equal") and -1 otherwise, otherwise return -1.
*/
gint
-tvb_strncaseeql(tvbuff_t *tvb, const gint offset, const gchar *str, const gint size)
+tvb_strncaseeql(tvbuff_t *tvb, const gint offset, const gchar *str, const size_t size)
{
const guint8 *ptr;
- ptr = ensure_contiguous_no_exception(tvb, offset, size, NULL);
+ ptr = ensure_contiguous_no_exception(tvb, offset, (gint)size, NULL);
if (ptr) {
int cmp = g_ascii_strncasecmp((const char *)ptr, str, size);