Fix a warning by changing a pointer type.

text2pcap.c: In function ‘parse_token’:
text2pcap.c:1076: warning: cast from pointer to integer of different size
text2pcap.c:1076: warning: cast from pointer to integer of different size

svn path=/trunk/; revision=38702
This commit is contained in:
Stig Bjørlykke 2011-08-24 06:42:40 +00:00
parent cd850e3404
commit cf114c1124
1 changed files with 2 additions and 2 deletions

View File

@ -205,7 +205,7 @@ static char *ts_fmt = NULL;
static struct tm timecode_default;
static char new_date_fmt = 0;
static char* pkt_lnstart;
static unsigned char* pkt_lnstart;
/* Input file */
static const char *input_filename;
@ -1073,7 +1073,7 @@ parse_token (token_t token, char *str)
we should find out the largest tail of s1 matches the head
of s2, it means the matched part in tail is the ASCII dump
of the head byte. These matched should be rollback */
line_size = curr_offset-((int)pkt_lnstart-(int)packet_buf);
line_size = curr_offset-(pkt_lnstart-packet_buf);
s2 = (char*)malloc((line_size+1)/4+1);
/* gather the possible pattern */
for(i=0; i<(line_size+1)/4; i++) {