mirror of
https://github.com/Adaptix-Framework/AdaptixC2
synced 2026-06-08 10:20:39 +00:00
Add Browser - disk
This commit is contained in:
@@ -14,4 +14,21 @@ QString ReadFileString(const QString &filePath, bool* result)
|
||||
|
||||
*result = true;
|
||||
return content;
|
||||
}
|
||||
|
||||
QString GetRootPathWindows(const QString& path)
|
||||
{
|
||||
if (path.startsWith("\\\\")) {
|
||||
int secondSlash = path.indexOf('\\', 2);
|
||||
if (secondSlash != -1) {
|
||||
return path.left(secondSlash);
|
||||
}
|
||||
}
|
||||
|
||||
int firstSlash = path.indexOf('\\');
|
||||
if (firstSlash != -1) {
|
||||
return path.left(firstSlash);
|
||||
}
|
||||
|
||||
return path;
|
||||
}
|
||||
Reference in New Issue
Block a user