[Wireshark-dev] Can I safely use PCRE in wiretap file reader?

2010-09-18 Thread Hadriel Kaplan
Howdy, I'm writing a wiretap file reader for a format which uses ascii encoding for metadata, and I'd like to use regex/PCRE for it. (it would be a lot cleaner/simpler than sscanf) I'd like to be able to contribute this file reader back into mainline someday. Since PCRE is optional in the dev

Re: [Wireshark-dev] Can I safely use PCRE in wiretap file reader?

2010-09-18 Thread Stephen Fisher
On Sat, Sep 18, 2010 at 01:14:37PM -0400, Hadriel Kaplan wrote: Since PCRE is optional in the dev docs, does that mean I can't safely assume it's available in wireshark builds? Yes, however, we recently started using GLib's GRegex functionality in place of PCRE when running a high-enough

Re: [Wireshark-dev] Can I safely use PCRE in wiretap file reader?

2010-09-18 Thread Stephen Fisher
On Sat, Sep 18, 2010 at 11:33:03AM -0600, Stephen Fisher wrote: You can block out your wiretap code to only work when compiled with GLib 2.14 (which is most people, including all of the automated builds that people download) by using: I failed to mention that this is because our minimum

Re: [Wireshark-dev] Can I safely use PCRE in wiretap file reader?

2010-09-18 Thread Hadriel Kaplan
Hi, Thanks for the tip! (I had looked at GRegex but worried about older GLib, but version checking is fine with me) BTW, your answer of yes means I cannot safely use plain PCRE, or yes I can safely use it? -hadriel On Sep 18, 2010, at 1:33 PM, Stephen Fisher wrote: On Sat, Sep 18, 2010 at

Re: [Wireshark-dev] Can I safely use PCRE in wiretap file reader?

2010-09-18 Thread Stephen Fisher
On Sat, Sep 18, 2010 at 01:46:43PM -0400, Hadriel Kaplan wrote: Thanks for the tip! (I had looked at GRegex but worried about older GLib, but version checking is fine with me) BTW, your answer of yes means I cannot safely use plain PCRE, or yes I can safely use it? You can use PCRE

Re: [Wireshark-dev] Can I safely use PCRE in wiretap file reader?

2010-09-18 Thread Hadriel Kaplan
OK, cool, got it. thanks again! On Sep 18, 2010, at 4:44 PM, Stephen Fisher wrote: On Sat, Sep 18, 2010 at 01:46:43PM -0400, Hadriel Kaplan wrote: Thanks for the tip! (I had looked at GRegex but worried about older GLib, but version checking is fine with me) BTW, your answer of yes