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

Side by Side Diff: native_client_sdk/src/libraries/gtest/nacl_gtest_dummy_sys.cc

Issue 10825189: [NaCl SDK] Get nacl_mounts_tests building. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: windows fixes Created 8 years, 4 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
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #if defined(__native_client__)
6 #include <errno.h>
7 #include <string.h>
8 #include <sys/types.h>
9 #endif
10
11 extern "C" {
12
13 #if defined(__native_client__)
14
15 char* getcwd(char* buf, size_t size) {
16 if (size < 2) {
17 errno = ERANGE;
18 return NULL;
19 }
20
21 return strncpy(buf, ".", size);
22 }
23
24 int unlink(const char* pathname) {
25 errno = ENOSYS;
26 return -1;
27 }
28
29 int mkdir(const char* pathname, mode_t mode) {
30 errno = ENOSYS;
31 return -1;
32 }
33
34 #endif
35
36 } // extern "C"
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698