ANNOUNCEMENT: Live Wireshark University & Allegro Packets online APAC Wireshark Training Session
July 17th, 2024 | 10:00am-11:55am SGT (UTC+8) | Online

Ethereal-dev: Re: [ethereal-dev] More routines in wiretap

Note: This archive is from the project's previous web site, ethereal.com. This list is no longer active.

From: Guy Harris <gharris@xxxxxxxxxxxx>
Date: Sat, 4 Dec 1999 13:22:17 -0800
> If we had "wtap_file_short_type_string()",

Or "wtap_file_type_short_string()", which makes more sense, given that
"type" is associated with "file", not "string", in
"wtap_file_type_string()".

I just checked "wtap_file_type_short_string()" in.

> we could construct a list of file types we can write with:

	...

> With that list, translating names to file types could be done by
> searching the list in question.

...or we could just add "wtap_short_string_to_file_type()", which takes
a short name and returns either a file type, or -1 if the short name
doesn't correspond to a file type we can write.

I just checked that in as well.

> That list could also be used in a usage message...

...but the usage message could be generated by a loop going through all
the file types and, for the ones we can write, listing
"wtap_file_short_type_string()" and "wtap_file_type_string()", so it's
not clear that building the list serves a useful purpose - hence I added
"wtap_short_string_to_file_type()".