mirror of
				https://github.com/PabloMK7/citra.git
				synced 2025-10-30 21:30:04 +00:00 
			
		
		
		
	file_util: return string by const reference for GetExeDirectory()
This disallows modifying the internal string buffer (which shouldn't be modified anyhow).
This commit is contained in:
		
							parent
							
								
									4a3c4f5f67
								
							
						
					
					
						commit
						99b2a871a7
					
				
					 2 changed files with 2 additions and 2 deletions
				
			
		|  | @ -591,7 +591,7 @@ std::string GetBundleDirectory() { | |||
| #endif | ||||
| 
 | ||||
| #ifdef _WIN32 | ||||
| std::string& GetExeDirectory() { | ||||
| const std::string& GetExeDirectory() { | ||||
|     static std::string exe_path; | ||||
|     if (exe_path.empty()) { | ||||
|         wchar_t wchar_exe_path[2048]; | ||||
|  |  | |||
|  | @ -133,7 +133,7 @@ std::string GetBundleDirectory(); | |||
| #endif | ||||
| 
 | ||||
| #ifdef _WIN32 | ||||
| std::string& GetExeDirectory(); | ||||
| const std::string& GetExeDirectory(); | ||||
| std::string AppDataRoamingDirectory(); | ||||
| #endif | ||||
| 
 | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue