Skip to content

Commit 59b3803

Browse files
Brad Milnetnyblom
Brad Milne
authored andcommitted
Log message when identity map doesn't have any valid lines
1 parent 5392048 commit 59b3803

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

Diff for: src/main.cpp

+5
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ QHash<QByteArray, QByteArray> loadIdentityMapFile(const QString &fileName)
4242
return result;
4343
}
4444

45+
bool found_author;
4546
while (!file.atEnd()) {
4647
QByteArray line = file.readLine();
4748
int comment_pos = line.indexOf('#');
@@ -68,9 +69,13 @@ QHash<QByteArray, QByteArray> loadIdentityMapFile(const QString &fileName)
6869
line.truncate(leftspace);
6970

7071
result.insert(line, realname);
72+
found_author = true;
7173
};
7274
file.close();
7375

76+
if(!found_author) {
77+
fprintf(stderr, "No authors found in identity-map file. Check supported formats.\n");
78+
}
7479
return result;
7580
}
7681

0 commit comments

Comments
 (0)