Wireshark-commits: [Wireshark-commits] rev 26151: /trunk/plugins/mate/ /trunk/plugins/mate/: mate_u
Date: Sat, 06 Sep 2008 18:27:34 GMT
http://anonsvn.wireshark.org/viewvc/viewvc.cgi?view=rev&revision=26151

User: guy
Date: 2008/09/06 11:27 AM

Log:
 To compute the difference between two addresses, cast the pointers
 holding those addresses to "void *" and then to "char *" (so we don't
 get warnings from casting directly to "char *" or errors from
 subtracting two "void *"s), and subtract them, rather than casting the
 pointers to an integral type possibly shorter than the pointers (to
 avoid warnings and to avoid the admittedly-infinitesimal chance that the
 two pointers don't differ in the bits that fit into the integral type).

Directory: /trunk/plugins/mate/
  Changes    Path           Action
  +17 -7     mate_util.c    Modified