mirror of
https://github.com/atom/atom.git
synced 2026-01-23 13:58:08 -05:00
Use relative path when tokenizing segments
Previously the raw path was used which may not have had a resolved home directory included in it.
This commit is contained in:
@@ -72,8 +72,8 @@ void NativeHandler::Absolute(const CefString& name,
|
||||
}
|
||||
|
||||
vector < string > segments;
|
||||
char allSegments[path.length() + 1];
|
||||
strcpy(allSegments, path.c_str());
|
||||
char allSegments[relativePath.length() + 1];
|
||||
strcpy(allSegments, relativePath.c_str());
|
||||
const char* segment;
|
||||
for (segment = strtok(allSegments, "/"); segment;
|
||||
segment = strtok(NULL, "/")) {
|
||||
|
||||
Reference in New Issue
Block a user