Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1289)

Unified Diff: runtime/bin/file_win.cc

Issue 12208109: Remove erroneous assert from Windows implementation of dart:io File.fullPath. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: address comments Created 7 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | tests/standalone/io/directory_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/bin/file_win.cc
diff --git a/runtime/bin/file_win.cc b/runtime/bin/file_win.cc
index 9f6bae8c171f5a1aeebf22a4dd17d8e77f901302..73d195caf14c939ab8712b4e07fc4b44e69c8265 100644
--- a/runtime/bin/file_win.cc
+++ b/runtime/bin/file_win.cc
@@ -209,7 +209,7 @@ char* File::GetCanonicalPath(const char* pathname) {
static_cast<wchar_t*>(malloc(required_size * sizeof(wchar_t)));
int written = GetFullPathNameW(system_name, required_size, path, NULL);
free(const_cast<wchar_t*>(system_name));
- ASSERT(written == (required_size - 1));
+ ASSERT(written <= (required_size - 1));
char* result = StringUtils::WideToUtf8(path);
free(path);
return result;
« no previous file with comments | « no previous file | tests/standalone/io/directory_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698