]> xenbits.xensource.com Git - people/royger/xen.git/commitdiff
tools/libxc: assign positive values to errno
authorOlaf Hering <olaf@aepfle.de>
Fri, 7 Mar 2014 09:15:07 +0000 (10:15 +0100)
committerIan Jackson <Ian.Jackson@eu.citrix.com>
Mon, 10 Mar 2014 16:50:58 +0000 (16:50 +0000)
Signed-off-by: Olaf Hering <olaf@aepfle.de>
Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>
tools/libxc/xc_foreign_memory.c
tools/libxc/xc_mem_paging.c
tools/libxc/xc_minios.c

index 7dfc8172e7dd563327c3687db80e5f6d394caacf..43abf01a83001164aff50df203ee76f21557ebd4 100644 (file)
@@ -27,7 +27,7 @@ void *xc_map_foreign_pages(xc_interface *xch, uint32_t dom, int prot,
     int i, *err;
 
     if (num < 0) {
-        errno = -EINVAL;
+        errno = EINVAL;
         return NULL;
     }
 
index 269cbddebeae0cf902845e1443812281754f31a5..8aa7d4d34dc3e5ddac375c5308a6fd6539bc8a1d 100644 (file)
@@ -76,7 +76,7 @@ int xc_mem_paging_load(xc_interface *xch, domid_t domain_id,
 {
     int rc, old_errno;
 
-    errno = -EINVAL;
+    errno = EINVAL;
 
     if ( !buffer )
         return -1;
index a48f0de7b184e29ad296285632c3d58983bdc30d..e621417cf332688e05682be8e52f8d588b4a041a 100644 (file)
@@ -349,7 +349,7 @@ static int minios_evtchn_unbind(xc_evtchn *xce, xc_osdep_handle h, evtchn_port_t
         }
     }
     printf("Warning: couldn't find port %"PRId32" for xc handle %x\n", port, fd);
-    errno = -EINVAL;
+    errno = EINVAL;
     return -1;
 }