mirror of
https://github.com/libretro/RetroArch
synced 2025-01-26 09:35:21 +00:00
Revert "Use string_is_equal"
This reverts commit 49a290c3e66e593169989da962289da71d0cb3a5.
This commit is contained in:
parent
49a290c3e6
commit
eeae9a186f
@ -74,7 +74,7 @@ static void find_first_libretro_core(char *first_file,
|
||||
salamander_name, sizeof(salamander_name)))
|
||||
break;
|
||||
|
||||
if (string_is_equal(fname, salamander_name))
|
||||
if (!strncmp(fname, salamander_name, sizeof(fname)))
|
||||
{
|
||||
if (list->size == (i + 1))
|
||||
{
|
||||
|
@ -34,7 +34,6 @@
|
||||
|
||||
#include <streams/file_stream.h>
|
||||
#include <retro_endianness.h>
|
||||
#include <string/stdstring.h>
|
||||
#include <compat/strl.h>
|
||||
|
||||
#include "libretrodb.h"
|
||||
@ -228,7 +227,7 @@ int libretrodb_open(const char *path, libretrodb_t *db)
|
||||
goto error;
|
||||
}
|
||||
|
||||
if (!string_is_equal(header.magic_number, MAGIC_NUMBER))
|
||||
if (strncmp(header.magic_number, MAGIC_NUMBER, sizeof(MAGIC_NUMBER)) != 0)
|
||||
{
|
||||
rv = -EINVAL;
|
||||
goto error;
|
||||
@ -265,7 +264,7 @@ static int libretrodb_find_index(libretrodb_t *db, const char *index_name,
|
||||
{
|
||||
libretrodb_read_index_header(db->fd, idx);
|
||||
|
||||
if (string_is_equal(index_name, idx->name))
|
||||
if (strncmp(index_name, idx->name, strlen(idx->name)) == 0)
|
||||
return 0;
|
||||
|
||||
offset = filestream_seek(db->fd, (ssize_t)idx->next, SEEK_CUR);
|
||||
|
@ -32,7 +32,6 @@
|
||||
|
||||
#include <compat/fnmatch.h>
|
||||
#include <compat/strl.h>
|
||||
#include <string/stdstring.h>
|
||||
|
||||
#include "libretrodb.h"
|
||||
#include "query.h"
|
||||
@ -469,7 +468,8 @@ static int query_peek(struct buffer buff, const char * data)
|
||||
if (remain < strlen(data))
|
||||
return 0;
|
||||
|
||||
return (int)string_is_equal(buff.data + buff.offset, data);
|
||||
return (strncmp(buff.data + buff.offset,
|
||||
data, strlen(data)) == 0);
|
||||
}
|
||||
|
||||
static int query_is_eot(struct buffer buff)
|
||||
@ -723,7 +723,7 @@ static struct buffer query_parse_method_call(struct buffer buff,
|
||||
|
||||
while (rf->name)
|
||||
{
|
||||
if (string_is_equal(rf->name, func_name))
|
||||
if (strncmp(rf->name, func_name, func_name_len) == 0)
|
||||
{
|
||||
invocation->func = rf->func;
|
||||
break;
|
||||
|
Loading…
x
Reference in New Issue
Block a user