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

Side by Side Diff: src/shared/platform/win/nacl_host_desc.c

Issue 195393003: Enable syscall_test on windows. (Closed) Base URL: svn://svn.chromium.org/native_client/trunk/src/native_client
Patch Set: Created 6 years, 9 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 | src/shared/platform/win/nacl_host_dir_types.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2012 The Native Client Authors. All rights reserved. 2 * Copyright (c) 2012 The Native Client Authors. All rights reserved.
3 * Use of this source code is governed by a BSD-style license that can be 3 * Use of this source code is governed by a BSD-style license that can be
4 * found in the LICENSE file. 4 * found in the LICENSE file.
5 */ 5 */
6 6
7 /* 7 /*
8 * NaCl Service Runtime. I/O Descriptor / Handle abstraction. Memory 8 * NaCl Service Runtime. I/O Descriptor / Handle abstraction. Memory
9 * mapping using descriptors. 9 * mapping using descriptors.
10 */ 10 */
(...skipping 1321 matching lines...) Expand 10 before | Expand all | Expand 10 after
1332 } 1332 }
1333 1333
1334 return 0; 1334 return 0;
1335 } 1335 }
1336 1336
1337 int NaClHostDescIsatty(struct NaClHostDesc *d) { 1337 int NaClHostDescIsatty(struct NaClHostDesc *d) {
1338 int retval; 1338 int retval;
1339 1339
1340 NaClHostDescCheckValidity("NaClHostDescIsatty", d); 1340 NaClHostDescCheckValidity("NaClHostDescIsatty", d);
1341 retval = _isatty(d->d); 1341 retval = _isatty(d->d);
1342 /* When _isatty fails it returns zero and sets errno. */ 1342 /* When windows _isatty fails it returns zero, but does not set errno. */
1343 return (0 == retval) ? -NaClXlateErrno(errno) : 1; 1343 return (0 == retval) ? -NACL_ABI_ENOTTY : 1;
1344 } 1344 }
1345 1345
1346 int NaClHostDescClose(struct NaClHostDesc *d) { 1346 int NaClHostDescClose(struct NaClHostDesc *d) {
1347 int retval; 1347 int retval;
1348 1348
1349 NaClHostDescCheckValidity("NaClHostDescClose", d); 1349 NaClHostDescCheckValidity("NaClHostDescClose", d);
1350 if (-1 != d->d) { 1350 if (-1 != d->d) {
1351 retval = _close(d->d); 1351 retval = _close(d->d);
1352 if (-1 == retval) { 1352 if (-1 == retval) {
1353 return -GetErrno(); 1353 return -GetErrno();
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
1394 if (_getcwd(path, (int) len) == NULL) 1394 if (_getcwd(path, (int) len) == NULL)
1395 return -NaClXlateErrno(errno); 1395 return -NaClXlateErrno(errno);
1396 return 0; 1396 return 0;
1397 } 1397 }
1398 1398
1399 int NaClHostDescUnlink(const char *path) { 1399 int NaClHostDescUnlink(const char *path) {
1400 if (_unlink(path) != 0) 1400 if (_unlink(path) != 0)
1401 return -errno; 1401 return -errno;
1402 return 0; 1402 return 0;
1403 } 1403 }
OLDNEW
« no previous file with comments | « no previous file | src/shared/platform/win/nacl_host_dir_types.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698