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

Side by Side Diff: native_client_sdk/src/libraries/nacl_io/kernel_proxy.cc

Issue 125693002: Implement lstat by stat in nacl_io (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 11 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | native_client_sdk/src/tests/nacl_io_test/kernel_proxy_test.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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "nacl_io/kernel_proxy.h" 5 #include "nacl_io/kernel_proxy.h"
6 6
7 #include <assert.h> 7 #include <assert.h>
8 #include <errno.h> 8 #include <errno.h>
9 #include <fcntl.h> 9 #include <fcntl.h>
10 #include <limits.h> 10 #include <limits.h>
(...skipping 616 matching lines...) Expand 10 before | Expand all | Expand 10 after
627 627
628 return 0; 628 return 0;
629 } 629 }
630 630
631 int KernelProxy::truncate(const char* path, off_t len) { 631 int KernelProxy::truncate(const char* path, off_t len) {
632 errno = ENOSYS; 632 errno = ENOSYS;
633 return -1; 633 return -1;
634 } 634 }
635 635
636 int KernelProxy::lstat(const char* path, struct stat* buf) { 636 int KernelProxy::lstat(const char* path, struct stat* buf) {
637 errno = ENOSYS; 637 return stat(path, buf);
638 return -1;
639 } 638 }
640 639
641 int KernelProxy::rename(const char* path, const char* newpath) { 640 int KernelProxy::rename(const char* path, const char* newpath) {
642 ScopedFilesystem fs; 641 ScopedFilesystem fs;
643 Path rel; 642 Path rel;
644 Error error = AcquireFsAndRelPath(path, &fs, &rel); 643 Error error = AcquireFsAndRelPath(path, &fs, &rel);
645 if (error) { 644 if (error) {
646 errno = error; 645 errno = error;
647 return -1; 646 return -1;
648 } 647 }
(...skipping 952 matching lines...) Expand 10 before | Expand all | Expand 10 after
1601 errno = ENOTSOCK; 1600 errno = ENOTSOCK;
1602 return -1; 1601 return -1;
1603 } 1602 }
1604 1603
1605 return 0; 1604 return 0;
1606 } 1605 }
1607 1606
1608 #endif // PROVIDES_SOCKET_API 1607 #endif // PROVIDES_SOCKET_API
1609 1608
1610 } // namespace_nacl_io 1609 } // namespace_nacl_io
OLDNEW
« no previous file with comments | « no previous file | native_client_sdk/src/tests/nacl_io_test/kernel_proxy_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698