mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-02-11 15:40:51 +00:00
Correct some non-const string literals.
Should not be treated as non-const char *.
This commit is contained in:
parent
80eb12a9d6
commit
bcf63a0fae
@ -14,7 +14,7 @@ std::vector<SFunc *> g_static_funcs_list;
|
|||||||
struct ModuleInfo
|
struct ModuleInfo
|
||||||
{
|
{
|
||||||
u32 id;
|
u32 id;
|
||||||
char* name;
|
const char* name;
|
||||||
}
|
}
|
||||||
static const g_module_list[] =
|
static const g_module_list[] =
|
||||||
{
|
{
|
||||||
|
@ -31,7 +31,7 @@ struct SFunc
|
|||||||
{
|
{
|
||||||
func_caller* func;
|
func_caller* func;
|
||||||
void* ptr;
|
void* ptr;
|
||||||
char* name;
|
const char* name;
|
||||||
std::vector<SFuncOp> ops;
|
std::vector<SFuncOp> ops;
|
||||||
u64 group;
|
u64 group;
|
||||||
u32 found;
|
u32 found;
|
||||||
@ -117,7 +117,7 @@ public:
|
|||||||
|
|
||||||
template<typename T> __forceinline void AddFunc(u32 id, T func);
|
template<typename T> __forceinline void AddFunc(u32 id, T func);
|
||||||
|
|
||||||
template<typename T> __forceinline void AddFuncSub(const char group[8], const u64 ops[], char* name, T func);
|
template<typename T> __forceinline void AddFuncSub(const char group[8], const u64 ops[], const char* name, T func);
|
||||||
};
|
};
|
||||||
|
|
||||||
template<typename T>
|
template<typename T>
|
||||||
@ -127,7 +127,7 @@ __forceinline void Module::AddFunc(u32 id, T func)
|
|||||||
}
|
}
|
||||||
|
|
||||||
template<typename T>
|
template<typename T>
|
||||||
__forceinline void Module::AddFuncSub(const char group[8], const u64 ops[], char* name, T func)
|
__forceinline void Module::AddFuncSub(const char group[8], const u64 ops[], const char* name, T func)
|
||||||
{
|
{
|
||||||
if (!ops[0]) return;
|
if (!ops[0]) return;
|
||||||
|
|
||||||
|
@ -64,7 +64,7 @@ bool TRPLoader::LoadHeader(bool show)
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool TRPLoader::ContainsEntry(char *filename)
|
bool TRPLoader::ContainsEntry(const char *filename)
|
||||||
{
|
{
|
||||||
for (const TRPEntry& entry : m_entries) {
|
for (const TRPEntry& entry : m_entries) {
|
||||||
if (!strcmp(entry.name, filename))
|
if (!strcmp(entry.name, filename))
|
||||||
@ -73,7 +73,7 @@ bool TRPLoader::ContainsEntry(char *filename)
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
void TRPLoader::RemoveEntry(char *filename)
|
void TRPLoader::RemoveEntry(const char *filename)
|
||||||
{
|
{
|
||||||
std::vector<TRPEntry>::iterator i = m_entries.begin();
|
std::vector<TRPEntry>::iterator i = m_entries.begin();
|
||||||
while (i != m_entries.end()) {
|
while (i != m_entries.end()) {
|
||||||
@ -84,7 +84,7 @@ void TRPLoader::RemoveEntry(char *filename)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void TRPLoader::RenameEntry(char *oldname, char *newname)
|
void TRPLoader::RenameEntry(const char *oldname, const char *newname)
|
||||||
{
|
{
|
||||||
for (const TRPEntry& entry : m_entries) {
|
for (const TRPEntry& entry : m_entries) {
|
||||||
if (!strcmp(entry.name, oldname))
|
if (!strcmp(entry.name, oldname))
|
||||||
|
@ -34,9 +34,9 @@ public:
|
|||||||
virtual bool Install(std::string dest, bool show = false);
|
virtual bool Install(std::string dest, bool show = false);
|
||||||
virtual bool LoadHeader(bool show = false);
|
virtual bool LoadHeader(bool show = false);
|
||||||
|
|
||||||
virtual bool ContainsEntry(char *filename);
|
virtual bool ContainsEntry(const char *filename);
|
||||||
virtual void RemoveEntry(char *filename);
|
virtual void RemoveEntry(const char *filename);
|
||||||
virtual void RenameEntry(char *oldname, char *newname);
|
virtual void RenameEntry(const char *oldname, const char *newname);
|
||||||
|
|
||||||
virtual bool Close();
|
virtual bool Close();
|
||||||
};
|
};
|
Loading…
x
Reference in New Issue
Block a user