extcap: Separate dirname and file with G_DIR_SEPARATOR_S.
authorStig Bjørlykke <stig@bjorlykke.org>
Wed, 7 Dec 2016 18:02:06 +0000 (19:02 +0100)
committerMichael Mann <mmann78@netscape.net>
Wed, 7 Dec 2016 19:46:49 +0000 (19:46 +0000)
Change-Id: I9e1e9b1a10a15ca95519392a7a19ba77f460141e
Reviewed-on: https://code.wireshark.org/review/19131
Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
extcap.c

index b900d084f566444a97c426a05e236f5b21cfa2ce..b56dd3a064fecb7c1f7494d38d6638c08490ddea 100644 (file)
--- a/extcap.c
+++ b/extcap.c
@@ -179,11 +179,7 @@ static void extcap_foreach(gint argc, gchar **args, extcap_cb_t cb,
             gchar *command_output = NULL;
 
             /* full path to extcap binary */
-#ifdef _WIN32
-            g_string_printf(extcap_path, "%s\\%s", dirname, file);
-#else
-            g_string_printf(extcap_path, "%s/%s", dirname, file);
-#endif
+            g_string_printf(extcap_path, "%s" G_DIR_SEPARATOR_S "%s", dirname, file);
             if ( extcap_if_exists(ifname) && !extcap_if_exists_for_extcap(ifname, extcap_path->str ) )
                 continue;