forked from osmocom/wireshark
Note that "uchar", "u_char", "u_short", "u_int", and "u_long" are also
forbidden. svn path=/trunk/; revision=9356
This commit is contained in:
parent
b3557944ff
commit
87347d7867
|
@ -1,4 +1,4 @@
|
|||
$Id: README.developer,v 1.86 2003/11/14 19:20:24 guy Exp $
|
||||
$Id: README.developer,v 1.87 2003/12/19 19:08:00 guy Exp $
|
||||
|
||||
This file is a HOWTO for Ethereal developers. It describes how to start coding
|
||||
a Ethereal protocol dissector and the use some of the important functions and
|
||||
|
@ -46,12 +46,15 @@ defined. Also, don't assume you can use "%lld", "%llu", "%llx", or
|
|||
"%llo" to print 64-bit integral data types - not all platforms support
|
||||
"%ll" for printing them.
|
||||
|
||||
Don't use "uint", "ulong" or "ushort"; they aren't defined on all
|
||||
platforms. If you want an "int-sized" unsigned quantity, use "guint";
|
||||
if you want a 32-bit unsigned quantity, use "guint32"; and if you want a
|
||||
16-bit unsigned quantity, use "guint16". Use "%d", "%u", "%x", and "%o"
|
||||
to print those types; don't use "%ld", "%lu", "%lx", or "%lo", as longs
|
||||
are 64 bits long on many platforms, but "guint32" is 32 bits long.
|
||||
Don't use "uchar", "u_char", "ushort", "u_short", "uint", "u_int",
|
||||
"ulong", or "u_long"; they aren't defined on all platforms. If you want
|
||||
an 8-bit unsigned quantity, use "guint8"; if you want an 8-bit character
|
||||
value with the 8th bit not interpreted as a sign bit, use "guchar"; if
|
||||
you want a 16-bit unsigned quantity, use "guint16"; if you want a 32-bit
|
||||
unsigned quantity, use "guint32"; and if you want an "int-sized"
|
||||
unsigned quantity, use "guint". Use "%d", "%u", "%x", and "%o" to print
|
||||
those types; don't use "%ld", "%lu", "%lx", or "%lo", as longs are 64
|
||||
bits long on many platforms, but "guint32" is 32 bits long.
|
||||
|
||||
Don't use "long" to mean "signed 32-bit integer", and don't use
|
||||
"unsigned long" to mean "unsigned 32-bit integer"; "long"s are 64 bits
|
||||
|
@ -247,7 +250,7 @@ code inside
|
|||
|
||||
is needed only if you are using the "snprintf()" function.
|
||||
|
||||
The "$Id: README.developer,v 1.86 2003/11/14 19:20:24 guy Exp $"
|
||||
The "$Id: README.developer,v 1.87 2003/12/19 19:08:00 guy Exp $"
|
||||
in the comment will be updated by CVS when the file is
|
||||
checked in; it will allow the RCS "ident" command to report which
|
||||
version of the file is currently checked out.
|
||||
|
@ -257,7 +260,7 @@ version of the file is currently checked out.
|
|||
* Routines for PROTONAME dissection
|
||||
* Copyright 2000, YOUR_NAME <YOUR_EMAIL_ADDRESS>
|
||||
*
|
||||
* $Id: README.developer,v 1.86 2003/11/14 19:20:24 guy Exp $
|
||||
* $Id: README.developer,v 1.87 2003/12/19 19:08:00 guy Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@ethereal.com>
|
||||
|
|
Loading…
Reference in New Issue