]> xenbits.xensource.com Git - libvirt.git/commitdiff
Remove translations in socket test case
authorDaniel P. Berrange <berrange@redhat.com>
Thu, 3 Nov 2011 10:52:44 +0000 (10:52 +0000)
committerDaniel P. Berrange <berrange@redhat.com>
Thu, 3 Nov 2011 10:52:44 +0000 (10:52 +0000)
The test case errors should not be translated since they're only
targetted at developers, not users.

* tests/virnetsockettest.c: Remove error reporting with translations

tests/virnetsockettest.c

index a76e5cccf1692bc3d2c814c5f060cd04c0655290..16713e830482277f26471ac1a2c5afe3ba1d0536 100644 (file)
@@ -207,14 +207,11 @@ static int testSocketUNIXAccept(const void *data ATTRIBUTE_UNUSED)
 
     tmpdir = mkdtemp(template);
     if (tmpdir == NULL) {
-        virReportSystemError(errno, "%s",
-                             _("Failed to create temporary directory"));
+        VIR_WARN("Failed to create temporary directory");
         goto cleanup;
     }
-    if (virAsprintf(&path, "%s/test.sock", tmpdir) < 0) {
-        virReportOOMError();
+    if (virAsprintf(&path, "%s/test.sock", tmpdir) < 0)
         goto cleanup;
-    }
 
     if (virNetSocketNewListenUNIX(path, 0700, -1, getgid(), &lsock) < 0)
         goto cleanup;
@@ -260,14 +257,11 @@ static int testSocketUNIXAddrs(const void *data ATTRIBUTE_UNUSED)
 
     tmpdir = mkdtemp(template);
     if (tmpdir == NULL) {
-        virReportSystemError(errno, "%s",
-                             _("Failed to create temporary directory"));
+        VIR_WARN("Failed to create temporary directory");
         goto cleanup;
     }
-    if (virAsprintf(&path, "%s/test.sock", tmpdir) < 0) {
-        virReportOOMError();
+    if (virAsprintf(&path, "%s/test.sock", tmpdir) < 0)
         goto cleanup;
-    }
 
     if (virNetSocketNewListenUNIX(path, 0700, -1, getgid(), &lsock) < 0)
         goto cleanup;