Cleanup: strcmp/strncmp -> STREQ/STREQLEN (in boolean usage).
Makes usage of those funcs much more clear, we even had mixed '!strcmp(foo, bar)' and 'strcmp(foo, bar) == 0' in several places...
This commit is contained in:
@@ -755,7 +755,7 @@ static int set_engine(int argc, const char **argv, void *data)
|
||||
{
|
||||
bContext *C = data;
|
||||
if (argc >= 2) {
|
||||
if (!strcmp(argv[1], "help")) {
|
||||
if (STREQ(argv[1], "help")) {
|
||||
RenderEngineType *type = NULL;
|
||||
printf("Blender Engine Listing:\n");
|
||||
for (type = R_engines.first; type; type = type->next) {
|
||||
@@ -925,11 +925,11 @@ static int set_ge_parameters(int argc, const char **argv, void *data)
|
||||
SYS_WriteCommandLineInt(syshandle, argv[a], 1);
|
||||
#endif
|
||||
/* doMipMap */
|
||||
if (!strcmp(argv[a], "nomipmap")) {
|
||||
if (STREQ(argv[a], "nomipmap")) {
|
||||
GPU_set_mipmap(0); //doMipMap = 0;
|
||||
}
|
||||
/* linearMipMap */
|
||||
if (!strcmp(argv[a], "linearmipmap")) {
|
||||
if (STREQ(argv[a], "linearmipmap")) {
|
||||
GPU_set_linear_mipmap(1); //linearMipMap = 1;
|
||||
}
|
||||
|
||||
@@ -1555,7 +1555,7 @@ int main(
|
||||
|
||||
#if defined(__APPLE__) && !defined(WITH_PYTHON_MODULE)
|
||||
/* patch to ignore argument finder gives us (pid?) */
|
||||
if (argc == 2 && strncmp(argv[1], "-psn_", 5) == 0) {
|
||||
if (argc == 2 && STREQLEN(argv[1], "-psn_", 5)) {
|
||||
extern int GHOST_HACK_getFirstFile(char buf[]);
|
||||
static char firstfilebuf[512];
|
||||
|
||||
|
Reference in New Issue
Block a user