mirror of
https://github.com/CTCaer/RetroArch.git
synced 2025-01-20 18:02:12 +00:00
Use stdstring.h
This commit is contained in:
parent
5698bd489c
commit
f395e851c4
@ -32,6 +32,7 @@
|
||||
#endif
|
||||
|
||||
#include <compat/strl.h>
|
||||
#include <string/stdstring.h>
|
||||
#include <file/file_path.h>
|
||||
#ifndef IS_SALAMANDER
|
||||
#include <lists/file_list.h>
|
||||
@ -125,7 +126,7 @@ static void frontend_ps3_get_environment_settings(int *argc, char *argv[],
|
||||
/* not launched from external launcher, set default path */
|
||||
// second param is multiMAN SELF file
|
||||
if(path_file_exists(argv[2]) && *argc > 1
|
||||
&& (!strcmp(argv[2], EMULATOR_CONTENT_DIR)))
|
||||
&& (string_is_equal(argv[2], EMULATOR_CONTENT_DIR)))
|
||||
{
|
||||
multiman_detected = true;
|
||||
RARCH_LOG("Started from multiMAN, auto-game start enabled.\n");
|
||||
|
@ -17,6 +17,7 @@
|
||||
#include <string.h>
|
||||
|
||||
#include <compat/strl.h>
|
||||
#include <string/stdstring.h>
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "../config.h"
|
||||
@ -82,7 +83,7 @@ frontend_ctx_driver_t *frontend_ctx_find_driver(const char *ident)
|
||||
|
||||
for (i = 0; frontend_ctx_drivers[i]; i++)
|
||||
{
|
||||
if (!strcmp(frontend_ctx_drivers[i]->ident, ident))
|
||||
if (string_is_equal(frontend_ctx_drivers[i]->ident, ident))
|
||||
return frontend_ctx_drivers[i];
|
||||
}
|
||||
|
||||
|
@ -133,7 +133,7 @@ static void salamander_init(char *s, size_t len)
|
||||
config_get_array(conf, "libretro_path", tmp_str, sizeof(tmp_str));
|
||||
config_file_free(conf);
|
||||
|
||||
if (strcmp(tmp_str, "builtin") != 0)
|
||||
if (!string_is_equal(tmp_str, "builtin"))
|
||||
strlcpy(s, tmp_str, len);
|
||||
}
|
||||
#ifdef GEKKO
|
||||
@ -146,7 +146,7 @@ static void salamander_init(char *s, size_t len)
|
||||
#endif
|
||||
}
|
||||
|
||||
if (!config_file_exists || !strcmp(s, ""))
|
||||
if (!config_file_exists || string_is_equal(s, ""))
|
||||
{
|
||||
char executable_name[PATH_MAX_LENGTH];
|
||||
|
||||
|
@ -28,6 +28,7 @@
|
||||
#include <net/net_compat.h>
|
||||
#include <net/net_socket.h>
|
||||
#include <compat/strl.h>
|
||||
#include <string/stdstring.h>
|
||||
|
||||
enum
|
||||
{
|
||||
@ -350,7 +351,7 @@ bool net_http_update(struct http_t *state, size_t* progress, size_t* total)
|
||||
state->len = strtol(state->data +
|
||||
strlen("Content-Length: "), NULL, 10);
|
||||
}
|
||||
if (!strcmp(state->data, "Transfer-Encoding: chunked"))
|
||||
if (string_is_equal(state->data, "Transfer-Encoding: chunked"))
|
||||
state->bodytype = T_CHUNK;
|
||||
|
||||
/* TODO: save headers somewhere */
|
||||
|
@ -13,9 +13,10 @@ CFLAGS += -Wall -pedantic -std=gnu99
|
||||
|
||||
HTTP_TEST_C = \
|
||||
$(LIBRETRO_COMM_DIR)/net/net_http.c \
|
||||
net_http_test.c \
|
||||
$(LIBRETRO_COMM_DIR)/net/net_compat.c \
|
||||
$(LIBRETRO_COMM_DIR)/compat/compat_strl.c
|
||||
$(LIBRETRO_COMM_DIR)/compat/compat_strl.c \
|
||||
$(LIBRETRO_COMM_DIR)/string/stdstring.c \
|
||||
net_http_test.c
|
||||
|
||||
HTTP_TEST_OBJS := $(HTTP_TEST_C:.c=.o)
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user