getRecentName(): use realpath(3) instead of errorprone 'chdir()' calls
[util-vserver.git] / util-vserver / lib / ioctl-setfilecontext.hc
index c07f1ba..f39b993 100644 (file)
@@ -31,10 +31,7 @@ vc_X_set_filecontext(int fd, xid_t ctx)
   int  c  = ctx;
   int  rc = ioctl(fd, EXT2_IOC_SETCONTEXT, &c);
 
-  if (rc<-1) {
-    errno = -rc;
-    rc    = -1;
-  }
+  ENSC_FIX_IOCTL(rc);
   
   return rc;
 }