Chromium Code Reviews| Index: runtime/bin/directory_win.cc |
| diff --git a/runtime/bin/directory_win.cc b/runtime/bin/directory_win.cc |
| index dc6cd699b6855fe2bf26141912ab40f69748ba99..2da3998b28e48cc9a33387ba42d25d73948616ec 100644 |
| --- a/runtime/bin/directory_win.cc |
| +++ b/runtime/bin/directory_win.cc |
| @@ -425,6 +425,12 @@ char* Directory::Current() { |
| } |
| +bool Directory::SetCurrent(const char* path) { |
| + const wchar_t* system_path = StringUtils::Utf8ToWide(path); |
| + return SetCurrentDirectoryW(system_path) == 0; |
|
Bill Hesse
2013/04/29 11:01:12
free system_path?
Søren Gjesse
2013/04/29 11:59:15
Absolutely, thanks
|
| +} |
| + |
| + |
| bool Directory::Create(const char* dir_name) { |
| const wchar_t* system_name = StringUtils::Utf8ToWide(dir_name); |
| int create_status = CreateDirectoryW(system_name, NULL); |