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

Side by Side Diff: net/base/file_stream_win.cc

Issue 2937010: Reland r52336. (Closed) Base URL: http://src.chromium.org/git/chromium.git
Patch Set: Created 10 years, 5 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 unified diff | Download patch
« no previous file with comments | « net/base/file_stream_posix.cc ('k') | net/base/host_resolver_impl.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2008 The Chromium Authors. All rights reserved. Use of this 1 // Copyright (c) 2008 The Chromium Authors. All rights reserved. Use of this
2 // source code is governed by a BSD-style license that can be found in the 2 // source code is governed by a BSD-style license that can be found in the
3 // LICENSE file. 3 // LICENSE file.
4 4
5 #include "net/base/file_stream.h" 5 #include "net/base/file_stream.h"
6 6
7 #include <windows.h> 7 #include <windows.h>
8 8
9 #include "base/file_path.h" 9 #include "base/file_path.h"
10 #include "base/histogram.h"
10 #include "base/logging.h" 11 #include "base/logging.h"
11 #include "base/message_loop.h" 12 #include "base/message_loop.h"
12 #include "net/base/net_errors.h" 13 #include "net/base/net_errors.h"
13 14
14 namespace net { 15 namespace net {
15 16
16 // Ensure that we can just use our Whence values directly. 17 // Ensure that we can just use our Whence values directly.
17 COMPILE_ASSERT(FROM_BEGIN == FILE_BEGIN, bad_whence_begin); 18 COMPILE_ASSERT(FROM_BEGIN == FILE_BEGIN, bad_whence_begin);
18 COMPILE_ASSERT(FROM_CURRENT == FILE_CURRENT, bad_whence_current); 19 COMPILE_ASSERT(FROM_CURRENT == FILE_CURRENT, bad_whence_current);
19 COMPILE_ASSERT(FROM_END == FILE_END, bad_whence_end); 20 COMPILE_ASSERT(FROM_END == FILE_END, bad_whence_end);
(...skipping 315 matching lines...) Expand 10 before | Expand all | Expand 10 after
335 DWORD error = GetLastError(); 336 DWORD error = GetLastError();
336 LOG(WARNING) << "SetEndOfFile failed: " << error; 337 LOG(WARNING) << "SetEndOfFile failed: " << error;
337 return MapErrorCode(error); 338 return MapErrorCode(error);
338 } 339 }
339 340
340 // Success. 341 // Success.
341 return seek_position; 342 return seek_position;
342 } 343 }
343 344
344 } // namespace net 345 } // namespace net
OLDNEW
« no previous file with comments | « net/base/file_stream_posix.cc ('k') | net/base/host_resolver_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698