commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mt...@apache.org
Subject svn commit: r897925 - /commons/sandbox/runtime/trunk/src/main/native/port/basename.c
Date Mon, 11 Jan 2010 16:14:06 GMT
Author: mturk
Date: Mon Jan 11 16:14:05 2010
New Revision: 897925

URL: http://svn.apache.org/viewvc?rev=897925&view=rev
Log:
Use our error setting

Modified:
    commons/sandbox/runtime/trunk/src/main/native/port/basename.c

Modified: commons/sandbox/runtime/trunk/src/main/native/port/basename.c
URL: http://svn.apache.org/viewvc/commons/sandbox/runtime/trunk/src/main/native/port/basename.c?rev=897925&r1=897924&r2=897925&view=diff
==============================================================================
--- commons/sandbox/runtime/trunk/src/main/native/port/basename.c (original)
+++ commons/sandbox/runtime/trunk/src/main/native/port/basename.c Mon Jan 11 16:14:05 2010
@@ -34,6 +34,7 @@
 #include "acr_private.h"
 #include "acr_arch.h"
 #include "acr_port.h"
+#include "acr_error.h"
 
 #if defined(WIN32)
 #define IS_PSA(c) ((c) ==  '/' || (c) ==  '\\')
@@ -84,7 +85,7 @@
 
     len = endp - startp + 1;
     if (len >= blen) {
-        errno = ENOMEM;
+        ACR_SET_OS_ERROR(ACR_ENOMEM);
         return NULL;
     }
     memcpy(bname, startp, len);
@@ -132,7 +133,7 @@
 
     len = endp - startp + 1;
     if (len >= blen) {
-        errno = ENOMEM;
+        ACR_SET_OS_ERROR(ACR_ENOMEM);
         return NULL;
     }
     memcpy(bname, startp, len * sizeof(wchar_t));



Mime
View raw message