Reacted on compiler warnings of Debian 13 Sid about calloc argument swap
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
|
||||
/* xorriso - creates, loads, manipulates and burns ISO 9660 filesystem images.
|
||||
|
||||
Copyright 2007-2024 Thomas Schmitt, <scdbackup@gmx.net>
|
||||
Copyright 2007-2025 Thomas Schmitt, <scdbackup@gmx.net>
|
||||
|
||||
Provided under GPL version 2 or later.
|
||||
|
||||
@@ -891,8 +891,8 @@ int Findjob_set_num_filter(struct FindjoB *o, int test_type,
|
||||
|
||||
t= o->cursor->test;
|
||||
t->test_type= test_type;
|
||||
t->arg1= calloc(sizeof(int), 1);
|
||||
t->arg2= calloc(sizeof(int), 1);
|
||||
t->arg1= calloc(1, sizeof(int));
|
||||
t->arg2= calloc(1, sizeof(int));
|
||||
if(t->arg1 == NULL || t->arg2 == NULL)
|
||||
return(-1);
|
||||
*((int *) t->arg1)= num1;
|
||||
@@ -913,8 +913,8 @@ int Findjob_set_size_filter(struct FindjoB *o, int test_type,
|
||||
|
||||
t= o->cursor->test;
|
||||
t->test_type= test_type;
|
||||
t->arg1= calloc(sizeof(off_t), 1);
|
||||
t->arg2= calloc(sizeof(int), 1);
|
||||
t->arg1= calloc(1, sizeof(off_t));
|
||||
t->arg2= calloc(1, sizeof(int));
|
||||
if(t->arg1 == NULL || t->arg2 == NULL)
|
||||
return(-1);
|
||||
*((off_t *) t->arg1)= num1;
|
||||
@@ -935,8 +935,8 @@ int Findjob_set_off_t_filter(struct FindjoB *o, int test_type,
|
||||
|
||||
t= o->cursor->test;
|
||||
t->test_type= test_type;
|
||||
t->arg1= calloc(sizeof(off_t), 1);
|
||||
t->arg2= calloc(sizeof(off_t), 1);
|
||||
t->arg1= calloc(1, sizeof(off_t));
|
||||
t->arg2= calloc(1, sizeof(off_t));
|
||||
if(t->arg1 == NULL || t->arg2 == NULL)
|
||||
return(-1);
|
||||
*((off_t *) t->arg1)= num1;
|
||||
@@ -971,7 +971,7 @@ int Findjob_set_test_hidden(struct FindjoB *o, int mode, int flag)
|
||||
|
||||
t= o->cursor->test;
|
||||
t->test_type= 17;
|
||||
t->arg1= calloc(sizeof(int), 1);
|
||||
t->arg1= calloc(1, sizeof(int));
|
||||
if(t->arg1 == NULL)
|
||||
return(-1);
|
||||
*((int *) t->arg1)= mode;
|
||||
@@ -1110,7 +1110,7 @@ int Findjob_set_uint64_filter(struct FindjoB *o, int test_type, uint64_t value,
|
||||
|
||||
t= o->cursor->test;
|
||||
t->test_type= test_type;
|
||||
t->arg1= calloc(sizeof(uint64_t), 1);
|
||||
t->arg1= calloc(1, sizeof(uint64_t));
|
||||
*((uint64_t *) t->arg1)= value;
|
||||
return(1);
|
||||
}
|
||||
|
Reference in New Issue
Block a user