On 21 January 2013 17:27, Dirk Jagdmann <d...@cubic.org> wrote:

> the logical and is the very same in both revisions. But what makes this
> code
> confusing is the use of "prefs.capture_device" in one place and then
> "prefs_p->capture_device" in another. Maybe what you really want is
>
> if ((global_capture_opts.num_selected == 0) &&
>     (prefs.capture_device != NULL) &&
>     (prefs.capture_device[0] != '\0')) {
>
>
or replace the last element with something more descriptive of the test
being performed (I'm assuming a null terminated string):

(strlen(prefs.capture_device) > 0)
___________________________________________________________________________
Sent via:    Wireshark-dev mailing list <wireshark-dev@wireshark.org>
Archives:    http://www.wireshark.org/lists/wireshark-dev
Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev
             mailto:wireshark-dev-requ...@wireshark.org?subject=unsubscribe

Reply via email to