mirror of
https://github.com/gbdev/rgbds.git
synced 2025-11-20 18:22:07 +00:00
Fix -TAP being non-functional
This commit is contained in:
@@ -412,16 +412,18 @@ int main(int argc, char *argv[]) {
|
|||||||
#else
|
#else
|
||||||
"./"sv;
|
"./"sv;
|
||||||
#endif
|
#endif
|
||||||
|
size_t len = options.input.npos;
|
||||||
size_t i = options.input.find_last_of(chars);
|
size_t i = options.input.find_last_of(chars);
|
||||||
if (i != options.input.npos && options.input[i] == '.') {
|
if (i != options.input.npos && options.input[i] == '.') {
|
||||||
// We found the last dot, but check if it's part of a stem
|
// We found the last dot, but check if it's part of a stem
|
||||||
// (There must be a non-path separator character before it)
|
// (There must be a non-path separator character before it)
|
||||||
if (i != 0 && chars.find(options.input[i - 1], 1) == chars.npos) {
|
if (i != 0 && chars.find(options.input[i - 1], 1) == chars.npos) {
|
||||||
// We can replace the extension
|
// We can replace the extension
|
||||||
path.resize(i + 1); // Keep the dot, though
|
len = i;
|
||||||
path.append(extension);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
path.assign(options.input, 0, len);
|
||||||
|
path.append(extension);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
autoOutPath(autoAttrmap, options.attrmap, ".attrmap");
|
autoOutPath(autoAttrmap, options.attrmap, ".attrmap");
|
||||||
|
|||||||
Reference in New Issue
Block a user