Wireshark-dev: Re: [Wireshark-dev] how to add a struct in wireshark?
From: Guy Harris <[email protected]>
Date: Sat, 29 Mar 2014 11:07:55 -0700
On Mar 29, 2014, at 2:12 AM, "??????????" <[email protected]> wrote:

> what should i do to create a struct and use it in different files?

Do you want to have a single global "performance_test" structure?

If so, do

	extern performance performance_test;

in performance.h, do

	performance_test.index = 0;

rather than

	performance_test->index = 0;

in epan/dissectors/packet-ieee80211.c and, in at least one source file, make sure you include "performance.h" *AND* do

	performance performance_test;

so that it's not just declared, but defined, in at least one file.