Fix calloc args, should be swapped these days

Signed-off-by: Bogomil Vasilev <smirky@smirky.net>
This commit is contained in:
2026-02-11 16:28:18 +02:00
parent eebf004291
commit 1d0172e4ee

View File

@@ -83,7 +83,7 @@ int main(int argc, char *argv[])
char path[] = "/etc/rmps/rmps.conf"; char path[] = "/etc/rmps/rmps.conf";
int path_size = strlen(path) + 1; int path_size = strlen(path) + 1;
config = calloc(sizeof(char), path_size); config = calloc(path_size, sizeof(char));
if (config == NULL) { if (config == NULL) {
fprintf(stderr, "calloc() failed for config\n"); fprintf(stderr, "calloc() failed for config\n");
exit(EXIT_FAILURE); exit(EXIT_FAILURE);