* By Gerald Combs <gerald@wireshark.org>
* Copyright 1998 Gerald Combs
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ * SPDX-License-Identifier: GPL-2.0-or-later
*/
#include <config.h>
#endif
#include <wsutil/strtoi.h>
+#include <wsutil/win32-utils.h>
#include "sharkd.h"
PROCESS_INFORMATION pi;
STARTUPINFO si;
char *exename;
- gunichar2 *commandline;
#endif
socket_handle_t fd;
si.hStdError = GetStdHandle(STD_ERROR_HANDLE);
exename = g_strdup_printf("%s\\%s", get_progfile_dir(), "sharkd.exe");
- commandline = g_utf8_to_utf16("sharkd.exe -", -1, NULL, NULL, NULL);
- if (!CreateProcess(utf_8to16(exename), commandline, NULL, NULL, TRUE, 0, NULL, NULL, &si, &pi))
+ if (!win32_create_process(exename, "sharkd.exe -", NULL, NULL, TRUE, 0, NULL, NULL, &si, &pi))
{
- fprintf(stderr, "CreateProcess(%s) failed\n", exename);
+ fprintf(stderr, "win32_create_process(%s) failed\n", exename);
}
else
{
}
g_free(exename);
- g_free(commandline);
#endif
closesocket(fd);