Bug ID |
8357
|
Summary |
Lua __tostring() metamethod of FieldInfo can cause error
|
Classification |
Unclassified
|
Product |
Wireshark
|
Version |
1.9.x (Experimental)
|
Hardware |
x86
|
OS |
Mac OS X 10.8
|
Status |
UNCONFIRMED
|
Severity |
Minor
|
Priority |
Low
|
Component |
Wireshark
|
Assignee |
[email protected]
|
Reporter |
[email protected]
|
Build Information:
Version 1.9.0 (SVN Rev 47651 from /trunk)
Copyright 1998-2013 Gerald Combs <[email protected]> and contributors.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Compiled (64-bit) with GTK+ 2.24.15, with Cairo 1.12.14, with Pango 1.32.5,
with
GLib 2.34.3, with libpcap, with libz 1.2.7, without POSIX capabilities, without
libnl, without SMI, without c-ares, without ADNS, with Lua 5.1, without Python,
with GnuTLS 2.12.19, with Gcrypt 1.5.0, with MIT Kerberos, without GeoIP,
without PortAudio, with AirPcap.
Running on Mac OS X 10.8.2, build 12C60 (Darwin 12.2.0), with locale
en_US.UTF-8, with libpcap version 1.3.0, with libz 1.2.7, GnuTLS 2.12.19,
Gcrypt
1.5.0, without AirPcap.
Intel(R) Core(TM) i7 CPU M 620 @ 2.67GHz
Built using llvm-gcc 4.2.1 (Based on Apple Inc. build 5658) (LLVM build
2336.11.00).
--
Using the __tostring metamethod on FieldInfo objects during run-time can cause
a Lua error to occur. This happens because the FieldInfo is of a type that
doesn't have a string representation. But the expectation from most Lua
developers would be this should not cause an error, but instead return a known
string, such as "(unknown)" or "(none)", etc. A Lua error is for when there's
really something wrong, either an error in the C-side or Lua-side code.
Also, the string returned (when one is returned) is not exactly what the GUI
displays in all cases. Seems to me a Lua developer would expect it to be what
the GUI displays for that Field, although changing __tostring at this point
might not be good.
You are receiving this mail because:
- You are watching all bug changes.