1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-31 18:55:23 +01:00

free path in screenshot.c

This commit is contained in:
IntelOrca
2014-05-26 14:14:03 +01:00
parent ac2521526b
commit a22534e099

View File

@@ -62,6 +62,8 @@ static int screenshot_get_next_path(char *path, char *extension)
{
char *screenshotPath = osinterface_get_orct2_homesubfolder("screenshot");
if (!osinterface_ensure_directory_exists(screenshotPath)) {
free(screenshotPath);
fprintf(stderr, "Unable to save screenshots in OpenRCT2 screenshot directory.\n");
return -1;
}
@@ -78,7 +80,6 @@ static int screenshot_get_next_path(char *path, char *extension)
}
free(screenshotPath);
return -1;
}