diff options
| author | in1tiate <radwoodward@vikings.grayson.edu> | 2021-11-15 17:03:36 -0600 |
|---|---|---|
| committer | in1tiate <radwoodward@vikings.grayson.edu> | 2021-11-15 17:03:36 -0600 |
| commit | 658a1ae624e4757a580543dfab149d868ec7636c (patch) | |
| tree | 8b534e633f44de128c1d59bff30d6e0bb6c7ef9f | |
| parent | 101a5e506f77eb0a7282a4b5865fe498c954b049 (diff) | |
Add an explicit check for empty string to dir_exists
| -rw-r--r-- | src/file_functions.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/file_functions.cpp b/src/file_functions.cpp index 37cdc32c..95e9b5f4 100644 --- a/src/file_functions.cpp +++ b/src/file_functions.cpp @@ -12,6 +12,9 @@ bool file_exists(QString file_path) bool dir_exists(QString dir_path) { + if (dir_path == "") + return false; + QDir check_dir(dir_path); return check_dir.exists(); |
