The libpcap callback "user" argument *should* have been a "void *", as

it's a pointer to an arbitrary object, assumed to be correctly aligned,
not a pointer to a not-necessarily-properly-aligned array of bytes. 
Cast it, so we won't get alignment warnings.

svn path=/trunk/; revision=21940
This commit is contained in:
Guy Harris 2007-05-25 19:31:13 +00:00
parent f2c8e0c0ba
commit 4e008159c8
1 changed files with 1 additions and 1 deletions

View File

@ -1941,7 +1941,7 @@ capture_pcap_cb(u_char *user, const struct pcap_pkthdr *phdr,
struct wtap_pkthdr whdr;
union wtap_pseudo_header pseudo_header;
const guchar *wtap_pd;
loop_data *ld = (loop_data *) user;
loop_data *ld = (void *) user;
int loop_err;
int err;
int save_file_fd;