Skip to content

Commit 50e8422

Browse files
authored
Update allsky_common.cpp: Implement callSaveImage
1 parent 93be903 commit 50e8422

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

src/allsky_common.cpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1003,7 +1003,7 @@ void displaySettings(config cg)
10031003
printf(" ZWO Exposure Type: %s\n", getZWOexposureType(cg.ZWOexposureType));
10041004
}
10051005
printf(" Preview: %s\n", yesNo(cg.preview));
1006-
if (cg.maxImages > 0) {
1006+
if (cg.maxImages != 0) {
10071007
printf(" Maximum images to take before exiting: %d\n", cg.maxImages);
10081008
}
10091009
printf(" Focus mode: %s\n", yesNo(cg.focusMode));
@@ -1345,6 +1345,10 @@ bool getCommandLineArguments(config *cg, int argc, char *argv[], bool readConfig
13451345
else if (strcmp(a, "maximages") == 0)
13461346
{
13471347
cg->maxImages = atoi(argv[++i]);
1348+
if (cg->maxImages < 0) {
1349+
cg->callSaveImage = false;
1350+
cg->maxImages = -(cg->maxImages);
1351+
}
13481352
}
13491353

13501354
// daytime settings

0 commit comments

Comments
 (0)