Fix calloc args, should be swapped these days
Signed-off-by: Bogomil Vasilev <smirky@smirky.net>
This commit is contained in:
@@ -83,7 +83,7 @@ int main(int argc, char *argv[])
|
||||
char path[] = "/etc/rmps/rmps.conf";
|
||||
int path_size = strlen(path) + 1;
|
||||
|
||||
config = calloc(sizeof(char), path_size);
|
||||
config = calloc(path_size, sizeof(char));
|
||||
if (config == NULL) {
|
||||
fprintf(stderr, "calloc() failed for config\n");
|
||||
exit(EXIT_FAILURE);
|
||||
|
||||
Reference in New Issue
Block a user