Skip to content

Commit

Permalink
Merge pull request #729 from linuxkidd/master
Browse files Browse the repository at this point in the history
Fixed extension check logic in startrails.cpp
  • Loading branch information
ckuethe authored Oct 25, 2021
2 parents 0d0d465 + 5907bac commit 9b89751
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/startrails.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -329,7 +329,7 @@ int main(int argc, char* argv[]) {
std::transform(extcheck.begin(), extcheck.end(), extcheck.begin(),
[](unsigned char c) { return std::tolower(c); });

if (extcheck.rfind(".png") == string::npos ||
if (extcheck.rfind(".png") == string::npos &&
extcheck.rfind(".jpg") == string::npos) {
fprintf(stderr,
KRED "Output file '%s' is missing extension (.jpg or .png)\n\n",
Expand Down

0 comments on commit 9b89751

Please sign in to comment.