[PATCH 1/2] Cleanup for a return statement in source files

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Return statements with parameter enclosed in parentheses were modified
and parentheses were removed. The whole change was scripted, here is how:

List of files was obtained using this command:
git grep -l -e '\<return\s*([^()]*\(([^()]*)[^()]*\)*)\s*;' |             \
grep -e '\.[ch]$' -e '\.py$'

Found files were modified with this command:
sed -i -e                                                                 \
's_^\(.*\<return\)\s*(\(\([^()]*([^()]*)[^()]*\)*\))\s*\(;.*$\)_\1 \2\4_' \
-e 's_^\(.*\<return\)\s*(\([^()]*\))\s*\(;.*$\)_\1 \2\3_'

Then checked for nonsenses.

The whole command looks like this:
git grep -l -e '\<return\s*([^()]*\(([^()]*)[^()]*\)*)\s*;' |             \
grep -e '\.[ch]$' -e '\.py$' | xargs sed -i -e                            \
's_^\(.*\<return\)\s*(\(\([^()]*([^()]*)[^()]*\)*\))\s*\(;.*$\)_\1 \2\4_' \
-e 's_^\(.*\<return\)\s*(\([^()]*\))\s*\(;.*$\)_\1 \2\3_'
---
 examples/dominfo/info1.c                  |    2 +-
 examples/domsuspend/suspend.c             |    6 +-
 python/generator.py                       |    8 +-
 python/libvirt-override.c                 |  216 +++++++++++++-------------
 python/libvirt-qemu-override.c            |    4 +-
 python/typewrappers.c                     |   76 +++++-----
 src/conf/domain_conf.c                    |   22 ++--
 src/conf/interface_conf.c                 |   70 +++++-----
 src/conf/nwfilter_params.c                |    2 +-
 src/cpu/cpu_x86.c                         |    2 +-
 src/datatypes.c                           |   80 +++++-----
 src/interface/netcf_driver.c              |    2 +-
 src/lxc/lxc_driver.c                      |    4 +-
 src/nwfilter/nwfilter_ebiptables_driver.c |    4 +-
 src/qemu/qemu_command.c                   |    6 +-
 src/qemu/qemu_driver.c                    |    4 +-
 src/qemu/qemu_process.c                   |    2 +-
 src/remote/remote_driver.c                |    2 +-
 src/security/security_selinux.c           |    2 +-
 src/test/test_driver.c                    |    8 +-
 src/util/conf.c                           |  106 +++++++-------
 src/util/hooks.c                          |   20 ++--
 src/util/sexpr.c                          |   14 +-
 src/util/util.c                           |    8 +-
 src/util/uuid.c                           |    6 +-
 src/util/virhash.c                        |   30 ++--
 src/util/virmacaddr.c                     |    2 +-
 src/util/virnetlink.c                     |    2 +-
 src/util/virsocketaddr.c                  |   48 +++---
 src/util/virterror.c                      |   14 +-
 src/util/xml.c                            |   50 +++---
 src/xen/xen_driver.c                      |   32 ++--
 src/xen/xen_hypervisor.c                  |  228 ++++++++++++++--------------
 src/xen/xend_internal.c                   |  234 ++++++++++++++--------------
 src/xen/xm_internal.c                     |   98 ++++++------
 src/xen/xs_internal.c                     |  120 ++++++++--------
 src/xenapi/xenapi_driver.c                |    2 +-
 src/xenxs/xen_sxpr.c                      |    2 +-
 src/xenxs/xen_xm.c                        |    2 +-
 tests/commandtest.c                       |    4 +-
 tests/cputest.c                           |    2 +-
 tests/domainsnapshotxml2xmltest.c         |    4 +-
 tests/interfacexml2xmltest.c              |    2 +-
 tests/networkxml2argvtest.c               |    2 +-
 tests/networkxml2xmltest.c                |    2 +-
 tests/nodedevxml2xmltest.c                |    2 +-
 tests/nodeinfotest.c                      |    2 +-
 tests/nwfilterxml2xmltest.c               |    2 +-
 tests/qemuargv2xmltest.c                  |    2 +-
 tests/qemuxml2argvtest.c                  |    2 +-
 tests/qemuxml2xmltest.c                   |    4 +-
 tests/qemuxmlnstest.c                     |    2 +-
 tests/qparamtest.c                        |    2 +-
 tests/sexpr2xmltest.c                     |    4 +-
 tests/sockettest.c                        |    2 +-
 tests/statstest.c                         |    2 +-
 tests/storagepoolxml2xmltest.c            |    2 +-
 tests/storagevolxml2xmltest.c             |    2 +-
 tests/virbuftest.c                        |    2 +-
 tests/virnetmessagetest.c                 |    2 +-
 tests/virnetsockettest.c                  |    4 +-
 tests/virnettlscontexttest.c              |    2 +-
 tests/virshtest.c                         |    2 +-
 tests/virtimetest.c                       |    2 +-
 tests/xencapstest.c                       |    2 +-
 tests/xmconfigtest.c                      |    4 +-
 tests/xml2sexprtest.c                     |    4 +-
 tools/virsh.c                             |    8 +-
 68 files changed, 809 insertions(+), 809 deletions(-)

diff --git a/examples/dominfo/info1.c b/examples/dominfo/info1.c
index 601e9f2..4d578bc 100644
--- a/examples/dominfo/info1.c
+++ b/examples/dominfo/info1.c
@@ -59,5 +59,5 @@ int main() {

     getDomainInfo(0);

-    return(0);
+    return 0;
 }
diff --git a/examples/domsuspend/suspend.c b/examples/domsuspend/suspend.c
index bae1b8d..a6311d1 100644
--- a/examples/domsuspend/suspend.c
+++ b/examples/domsuspend/suspend.c
@@ -30,9 +30,9 @@ checkDomainState(virDomainPtr dom) {

     ret = virDomainGetInfo(dom, &info);
     if (ret < 0) {
-        return(-1);
+        return -1;
     }
-    return(info.state);
+    return info.state;
 }

 /**
@@ -130,5 +130,5 @@ int main(int argc, char **argv) {
 error:
     if (conn != NULL)
         virConnectClose(conn);
-    return(0);
+    return 0;
 }
diff --git a/python/generator.py b/python/generator.py
index e641c31..57055ff 100755
--- a/python/generator.py
+++ b/python/generator.py
@@ -589,7 +589,7 @@ def print_function_wrapper(module, name, output, export, include):
                                                    args[1][0])
         else:
             c_call = "\n    %s(%s);\n" % (name, c_call);
-        ret_convert = "    Py_INCREF(Py_None);\n    return(Py_None);\n"
+        ret_convert = "    Py_INCREF(Py_None);\n    return Py_None;\n"
     elif py_types.has_key(ret[0]):
         (f, t, n, c) = py_types[ret[0]]
         c_return = "    %s c_retval;\n" % (ret[0])
@@ -598,13 +598,13 @@ def print_function_wrapper(module, name, output, export, include):
         else:
             c_call = "\n    c_retval = %s(%s);\n" % (name, c_call);
         ret_convert = "    py_retval = libvirt_%sWrap((%s) c_retval);\n" % (n,c)
-        ret_convert = ret_convert + "    return(py_retval);\n"
+        ret_convert = ret_convert + "    return py_retval;\n"
     elif py_return_types.has_key(ret[0]):
         (f, t, n, c) = py_return_types[ret[0]]
         c_return = "    %s c_retval;\n" % (ret[0])
         c_call = "\n    c_retval = %s(%s);\n" % (name, c_call);
         ret_convert = "    py_retval = libvirt_%sWrap((%s) c_retval);\n" % (n,c)
-        ret_convert = ret_convert + "    return(py_retval);\n"
+        ret_convert = ret_convert + "    return py_retval;\n"
     else:
         if skipped_types.has_key(ret[0]):
             return 0
@@ -663,7 +663,7 @@ def print_function_wrapper(module, name, output, export, include):
     if format != "":
         output.write("\n    if (!PyArg_ParseTuple(args, (char *)\"%s\"%s))\n" %
                      (format, format_args))
-        output.write("        return(NULL);\n")
+        output.write("        return NULL;\n")
     if c_convert != "":
         output.write(c_convert + "\n")

diff --git a/python/libvirt-override.c b/python/libvirt-override.c
index 22ee975..c866650 100644
--- a/python/libvirt-override.c
+++ b/python/libvirt-override.c
@@ -308,7 +308,7 @@ libvirt_virDomainBlockStats(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {

     if (!PyArg_ParseTuple(args, (char *)"Oz:virDomainBlockStats",
         &pyobj_domain,&path))
-        return(NULL);
+        return NULL;
     domain = (virDomainPtr) PyvirDomain_Get(pyobj_domain);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -326,7 +326,7 @@ libvirt_virDomainBlockStats(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
     PyTuple_SetItem(info, 2, PyLong_FromLongLong(stats.wr_req));
     PyTuple_SetItem(info, 3, PyLong_FromLongLong(stats.wr_bytes));
     PyTuple_SetItem(info, 4, PyLong_FromLongLong(stats.errs));
-    return(info);
+    return info;
 }

 static PyObject *
@@ -388,7 +388,7 @@ libvirt_virDomainInterfaceStats(PyObject *self ATTRIBUTE_UNUSED, PyObject *args)

     if (!PyArg_ParseTuple(args, (char *)"Oz:virDomainInterfaceStats",
         &pyobj_domain,&path))
-        return(NULL);
+        return NULL;
     domain = (virDomainPtr) PyvirDomain_Get(pyobj_domain);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -409,7 +409,7 @@ libvirt_virDomainInterfaceStats(PyObject *self ATTRIBUTE_UNUSED, PyObject *args)
     PyTuple_SetItem(info, 5, PyLong_FromLongLong(stats.tx_packets));
     PyTuple_SetItem(info, 6, PyLong_FromLongLong(stats.tx_errs));
     PyTuple_SetItem(info, 7, PyLong_FromLongLong(stats.tx_drop));
-    return(info);
+    return info;
 }

 static PyObject *
@@ -421,7 +421,7 @@ libvirt_virDomainMemoryStats(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
     PyObject *info;

     if (!PyArg_ParseTuple(args, (char *)"O:virDomainMemoryStats", &pyobj_domain))
-        return(NULL);
+        return NULL;
     domain = (virDomainPtr) PyvirDomain_Get(pyobj_domain);

     nr_stats = virDomainMemoryStats(domain, stats,
@@ -472,7 +472,7 @@ libvirt_virDomainGetSchedulerType(PyObject *self ATTRIBUTE_UNUSED,

     if (!PyArg_ParseTuple(args, (char *)"O:virDomainGetScedulerType",
                           &pyobj_domain))
-        return(NULL);
+        return NULL;
     domain = (virDomainPtr) PyvirDomain_Get(pyobj_domain);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -490,7 +490,7 @@ libvirt_virDomainGetSchedulerType(PyObject *self ATTRIBUTE_UNUSED,
     PyTuple_SetItem(info, 0, libvirt_constcharPtrWrap(c_retval));
     PyTuple_SetItem(info, 1, PyInt_FromLong((long)nparams));
     VIR_FREE(c_retval);
-    return(info);
+    return info;
 }

 static PyObject *
@@ -1246,7 +1246,7 @@ libvirt_virDomainGetVcpus(PyObject *self ATTRIBUTE_UNUSED,

     if (!PyArg_ParseTuple(args, (char *)"O:virDomainGetVcpus",
                           &pyobj_domain))
-        return(NULL);
+        return NULL;
     domain = (virDomainPtr) PyvirDomain_Get(pyobj_domain);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -1311,7 +1311,7 @@ libvirt_virDomainGetVcpus(PyObject *self ATTRIBUTE_UNUSED,
     VIR_FREE(cpuinfo);
     VIR_FREE(cpumap);

-    return(pyretval);
+    return pyretval;

  cleanup:
     VIR_FREE(cpuinfo);
@@ -1341,7 +1341,7 @@ libvirt_virDomainPinVcpu(PyObject *self ATTRIBUTE_UNUSED,

     if (!PyArg_ParseTuple(args, (char *)"OiO:virDomainPinVcpu",
                           &pyobj_domain, &vcpu, &pycpumap))
-        return(NULL);
+        return NULL;
     domain = (virDomainPtr) PyvirDomain_Get(pyobj_domain);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -1388,7 +1388,7 @@ libvirt_virDomainPinVcpuFlags(PyObject *self ATTRIBUTE_UNUSED,

     if (!PyArg_ParseTuple(args, (char *)"OiOi:virDomainPinVcpuFlags",
                           &pyobj_domain, &vcpu, &pycpumap, &flags))
-        return(NULL);
+        return NULL;
     domain = (virDomainPtr) PyvirDomain_Get(pyobj_domain);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -1436,7 +1436,7 @@ libvirt_virDomainGetVcpuPinInfo(PyObject *self ATTRIBUTE_UNUSED,

     if (!PyArg_ParseTuple(args, (char *)"Oi:virDomainGetVcpuPinInfo",
                           &pyobj_domain, &flags))
-        return(NULL);
+        return NULL;
     domain = (virDomainPtr) PyvirDomain_Get(pyobj_domain);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -1532,7 +1532,7 @@ libvirt_virConnGetLastError(PyObject *self ATTRIBUTE_UNUSED, PyObject *args)
     PyObject *pyobj_conn;

     if (!PyArg_ParseTuple(args, (char *)"O:virConGetLastError", &pyobj_conn))
-        return(NULL);
+        return NULL;
     conn = (virConnectPtr) PyvirConnect_Get(pyobj_conn);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -1608,7 +1608,7 @@ libvirt_virRegisterErrorHandler(ATTRIBUTE_UNUSED PyObject * self,
     if (!PyArg_ParseTuple
         (args, (char *) "OO:xmlRegisterErrorHandler", &pyobj_f,
          &pyobj_ctx))
-        return (NULL);
+        return NULL;

     DEBUG("libvirt_virRegisterErrorHandler(%p, %p) called\n", pyobj_ctx,
           pyobj_f);
@@ -1634,7 +1634,7 @@ libvirt_virRegisterErrorHandler(ATTRIBUTE_UNUSED PyObject * self,
     }

     py_retval = libvirt_intWrap(1);
-    return (py_retval);
+    return py_retval;
 }

 static int virConnectCredCallbackWrapper(virConnectCredentialPtr cred,
@@ -1728,7 +1728,7 @@ libvirt_virConnectOpenAuth(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
     virConnectAuth auth;

     if (!PyArg_ParseTuple(args, (char *)"zOi:virConnectOpenAuth", &name, &pyauth, &flags))
-        return(NULL);
+        return NULL;

     pycredtype = PyList_GetItem(pyauth, 0);
     pycredcb = PyList_GetItem(pyauth, 1);
@@ -1753,7 +1753,7 @@ libvirt_virConnectOpenAuth(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
     LIBVIRT_END_ALLOW_THREADS;
     VIR_FREE(auth.credtype);
     py_retval = libvirt_virConnectPtrWrap((virConnectPtr) c_retval);
-    return(py_retval);
+    return py_retval;
 }


@@ -1802,7 +1802,7 @@ libvirt_virConnectGetVersion (PyObject *self ATTRIBUTE_UNUSED,

     if (!PyArg_ParseTuple(args, (char *)"O:virConnectGetVersion",
                           &pyobj_conn))
-        return(NULL);
+        return NULL;
     conn = (virConnectPtr) PyvirConnect_Get(pyobj_conn);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -1828,7 +1828,7 @@ libvirt_virConnectGetLibVersion (PyObject *self ATTRIBUTE_UNUSED,

     if (!PyArg_ParseTuple(args, (char *)"O:virConnectGetLibVersion",
                           &pyobj_conn))
-        return(NULL);
+        return NULL;
     conn = (virConnectPtr) PyvirConnect_Get(pyobj_conn);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -1853,7 +1853,7 @@ libvirt_virConnectListDomainsID(PyObject *self ATTRIBUTE_UNUSED,


     if (!PyArg_ParseTuple(args, (char *)"O:virConnectListDomains", &pyobj_conn))
-        return(NULL);
+        return NULL;
     conn = (virConnectPtr) PyvirConnect_Get(pyobj_conn);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -1883,7 +1883,7 @@ libvirt_virConnectListDomainsID(PyObject *self ATTRIBUTE_UNUSED,
         VIR_FREE(ids);
     }

-    return(py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -1897,7 +1897,7 @@ libvirt_virConnectListDefinedDomains(PyObject *self ATTRIBUTE_UNUSED,


     if (!PyArg_ParseTuple(args, (char *)"O:virConnectListDefinedDomains", &pyobj_conn))
-        return(NULL);
+        return NULL;
     conn = (virConnectPtr) PyvirConnect_Get(pyobj_conn);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -1927,7 +1927,7 @@ libvirt_virConnectListDefinedDomains(PyObject *self ATTRIBUTE_UNUSED,
         VIR_FREE(names);
     }

-    return(py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -1941,7 +1941,7 @@ libvirt_virDomainSnapshotListNames(PyObject *self ATTRIBUTE_UNUSED,
     unsigned int flags;

     if (!PyArg_ParseTuple(args, (char *)"Oi:virDomainSnapshotListNames", &pyobj_dom, &flags))
-        return(NULL);
+        return NULL;
     dom = (virDomainPtr) PyvirDomain_Get(pyobj_dom);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -1971,7 +1971,7 @@ libvirt_virDomainSnapshotListNames(PyObject *self ATTRIBUTE_UNUSED,
         VIR_FREE(names);
     }

-    return(py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -1985,7 +1985,7 @@ libvirt_virDomainSnapshotListChildrenNames(PyObject *self ATTRIBUTE_UNUSED,
     unsigned int flags;

     if (!PyArg_ParseTuple(args, (char *)"Oi:virDomainSnapshotListChildrenNames", &pyobj_snap, &flags))
-        return(NULL);
+        return NULL;
     snap = (virDomainSnapshotPtr) PyvirDomainSnapshot_Get(pyobj_snap);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -2015,7 +2015,7 @@ libvirt_virDomainSnapshotListChildrenNames(PyObject *self ATTRIBUTE_UNUSED,
         VIR_FREE(names);
     }

-    return(py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -2028,7 +2028,7 @@ libvirt_virDomainRevertToSnapshot(PyObject *self ATTRIBUTE_UNUSED,
     unsigned int flags;

     if (!PyArg_ParseTuple(args, (char *)"OOi:virDomainRevertToSnapshot", &pyobj_dom, &pyobj_snap, &flags))
-        return(NULL);
+        return NULL;
     snap = (virDomainSnapshotPtr) PyvirDomainSnapshot_Get(pyobj_snap);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -2049,7 +2049,7 @@ libvirt_virDomainGetInfo(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
     virDomainInfo info;

     if (!PyArg_ParseTuple(args, (char *)"O:virDomainGetInfo", &pyobj_domain))
-        return(NULL);
+        return NULL;
     domain = (virDomainPtr) PyvirDomain_Get(pyobj_domain);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -2064,7 +2064,7 @@ libvirt_virDomainGetInfo(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
     PyList_SetItem(py_retval, 3, libvirt_intWrap((int) info.nrVirtCpu));
     PyList_SetItem(py_retval, 4,
                    libvirt_longlongWrap((unsigned long long) info.cpuTime));
-    return(py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -2133,7 +2133,7 @@ libvirt_virDomainGetBlockInfo(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
     unsigned int flags;

     if (!PyArg_ParseTuple(args, (char *)"Ozi:virDomainGetInfo", &pyobj_domain, &path, &flags))
-        return(NULL);
+        return NULL;
     domain = (virDomainPtr) PyvirDomain_Get(pyobj_domain);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -2145,7 +2145,7 @@ libvirt_virDomainGetBlockInfo(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
     PyList_SetItem(py_retval, 0, libvirt_ulonglongWrap(info.capacity));
     PyList_SetItem(py_retval, 1, libvirt_ulonglongWrap(info.allocation));
     PyList_SetItem(py_retval, 2, libvirt_ulonglongWrap(info.physical));
-    return(py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -2157,7 +2157,7 @@ libvirt_virNodeGetInfo(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
     virNodeInfo info;

     if (!PyArg_ParseTuple(args, (char *)"O:virDomainGetInfo", &pyobj_conn))
-        return(NULL);
+        return NULL;
     conn = (virConnectPtr) PyvirConnect_Get(pyobj_conn);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -2174,7 +2174,7 @@ libvirt_virNodeGetInfo(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
     PyList_SetItem(py_retval, 5, libvirt_intWrap((int) info.sockets));
     PyList_SetItem(py_retval, 6, libvirt_intWrap((int) info.cores));
     PyList_SetItem(py_retval, 7, libvirt_intWrap((int) info.threads));
-    return(py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -2186,7 +2186,7 @@ libvirt_virDomainGetUUID(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
     int c_retval;

     if (!PyArg_ParseTuple(args, (char *)"O:virDomainGetUUID", &pyobj_domain))
-        return(NULL);
+        return NULL;
     domain = (virDomainPtr) PyvirDomain_Get(pyobj_domain);

     if (domain == NULL)
@@ -2199,7 +2199,7 @@ libvirt_virDomainGetUUID(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
         return VIR_PY_NONE;
     py_retval = PyString_FromStringAndSize((char *) &uuid[0], VIR_UUID_BUFLEN);

-    return(py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -2213,7 +2213,7 @@ libvirt_virDomainGetUUIDString(PyObject *self ATTRIBUTE_UNUSED,

     if (!PyArg_ParseTuple(args, (char *)"O:virDomainGetUUIDString",
                           &pyobj_dom))
-        return(NULL);
+        return NULL;
     dom = (virDomainPtr) PyvirDomain_Get(pyobj_dom);

     if (dom == NULL)
@@ -2226,7 +2226,7 @@ libvirt_virDomainGetUUIDString(PyObject *self ATTRIBUTE_UNUSED,
         return VIR_PY_NONE;

     py_retval = PyString_FromString((char *) &uuidstr[0]);
-    return(py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -2239,7 +2239,7 @@ libvirt_virDomainLookupByUUID(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
     int len;

     if (!PyArg_ParseTuple(args, (char *)"Oz#:virDomainLookupByUUID", &pyobj_conn, &uuid, &len))
-        return(NULL);
+        return NULL;
     conn = (virConnectPtr) PyvirConnect_Get(pyobj_conn);

     if ((uuid == NULL) || (len != VIR_UUID_BUFLEN))
@@ -2249,7 +2249,7 @@ libvirt_virDomainLookupByUUID(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
     c_retval = virDomainLookupByUUID(conn, uuid);
     LIBVIRT_END_ALLOW_THREADS;
     py_retval = libvirt_virDomainPtrWrap((virDomainPtr) c_retval);
-    return(py_retval);
+    return py_retval;
 }


@@ -2264,7 +2264,7 @@ libvirt_virConnectListNetworks(PyObject *self ATTRIBUTE_UNUSED,


     if (!PyArg_ParseTuple(args, (char *)"O:virConnectListNetworks", &pyobj_conn))
-        return(NULL);
+        return NULL;
     conn = (virConnectPtr) PyvirConnect_Get(pyobj_conn);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -2294,7 +2294,7 @@ libvirt_virConnectListNetworks(PyObject *self ATTRIBUTE_UNUSED,
         VIR_FREE(names);
     }

-    return(py_retval);
+    return py_retval;
 }


@@ -2309,7 +2309,7 @@ libvirt_virConnectListDefinedNetworks(PyObject *self ATTRIBUTE_UNUSED,


     if (!PyArg_ParseTuple(args, (char *)"O:virConnectListDefinedNetworks", &pyobj_conn))
-        return(NULL);
+        return NULL;
     conn = (virConnectPtr) PyvirConnect_Get(pyobj_conn);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -2339,7 +2339,7 @@ libvirt_virConnectListDefinedNetworks(PyObject *self ATTRIBUTE_UNUSED,
         VIR_FREE(names);
     }

-    return(py_retval);
+    return py_retval;
 }


@@ -2352,7 +2352,7 @@ libvirt_virNetworkGetUUID(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
     int c_retval;

     if (!PyArg_ParseTuple(args, (char *)"O:virNetworkGetUUID", &pyobj_domain))
-        return(NULL);
+        return NULL;
     domain = (virNetworkPtr) PyvirNetwork_Get(pyobj_domain);

     if (domain == NULL)
@@ -2365,7 +2365,7 @@ libvirt_virNetworkGetUUID(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
         return VIR_PY_NONE;
     py_retval = PyString_FromStringAndSize((char *) &uuid[0], VIR_UUID_BUFLEN);

-    return(py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -2379,7 +2379,7 @@ libvirt_virNetworkGetUUIDString(PyObject *self ATTRIBUTE_UNUSED,

     if (!PyArg_ParseTuple(args, (char *)"O:virNetworkGetUUIDString",
                           &pyobj_net))
-        return(NULL);
+        return NULL;
     net = (virNetworkPtr) PyvirNetwork_Get(pyobj_net);

     if (net == NULL)
@@ -2392,7 +2392,7 @@ libvirt_virNetworkGetUUIDString(PyObject *self ATTRIBUTE_UNUSED,
         return VIR_PY_NONE;

     py_retval = PyString_FromString((char *) &uuidstr[0]);
-    return(py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -2405,7 +2405,7 @@ libvirt_virNetworkLookupByUUID(PyObject *self ATTRIBUTE_UNUSED, PyObject *args)
     int len;

     if (!PyArg_ParseTuple(args, (char *)"Oz#:virNetworkLookupByUUID", &pyobj_conn, &uuid, &len))
-        return(NULL);
+        return NULL;
     conn = (virConnectPtr) PyvirConnect_Get(pyobj_conn);

     if ((uuid == NULL) || (len != VIR_UUID_BUFLEN))
@@ -2415,7 +2415,7 @@ libvirt_virNetworkLookupByUUID(PyObject *self ATTRIBUTE_UNUSED, PyObject *args)
     c_retval = virNetworkLookupByUUID(conn, uuid);
     LIBVIRT_END_ALLOW_THREADS;
     py_retval = libvirt_virNetworkPtrWrap((virNetworkPtr) c_retval);
-    return(py_retval);
+    return py_retval;
 }


@@ -2427,7 +2427,7 @@ libvirt_virDomainGetAutostart(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
     PyObject *pyobj_domain;

     if (!PyArg_ParseTuple(args, (char *)"O:virDomainGetAutostart", &pyobj_domain))
-        return(NULL);
+        return NULL;

     domain = (virDomainPtr) PyvirDomain_Get(pyobj_domain);

@@ -2438,7 +2438,7 @@ libvirt_virDomainGetAutostart(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
     if (c_retval < 0)
         return VIR_PY_INT_FAIL;
     py_retval = libvirt_intWrap(autostart);
-    return(py_retval);
+    return py_retval;
 }


@@ -2450,7 +2450,7 @@ libvirt_virNetworkGetAutostart(PyObject *self ATTRIBUTE_UNUSED, PyObject *args)
     PyObject *pyobj_network;

     if (!PyArg_ParseTuple(args, (char *)"O:virNetworkGetAutostart", &pyobj_network))
-        return(NULL);
+        return NULL;

     network = (virNetworkPtr) PyvirNetwork_Get(pyobj_network);

@@ -2461,7 +2461,7 @@ libvirt_virNetworkGetAutostart(PyObject *self ATTRIBUTE_UNUSED, PyObject *args)
     if (c_retval < 0)
         return VIR_PY_INT_FAIL;
     py_retval = libvirt_intWrap(autostart);
-    return(py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -2474,7 +2474,7 @@ libvirt_virNodeGetCellsFreeMemory(PyObject *self ATTRIBUTE_UNUSED, PyObject *arg
     unsigned long long *freeMems;

     if (!PyArg_ParseTuple(args, (char *)"Oii:virNodeGetCellsFreeMemory", &pyobj_conn, &startCell, &maxCells))
-        return(NULL);
+        return NULL;

     if ((startCell < 0) || (maxCells <= 0) || (startCell + maxCells > 10000))
         return VIR_PY_NONE;
@@ -2497,7 +2497,7 @@ libvirt_virNodeGetCellsFreeMemory(PyObject *self ATTRIBUTE_UNUSED, PyObject *arg
                 libvirt_longlongWrap((long long) freeMems[i]));
     }
     VIR_FREE(freeMems);
-    return(py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -2637,7 +2637,7 @@ libvirt_virConnectListStoragePools(PyObject *self ATTRIBUTE_UNUSED,


     if (!PyArg_ParseTuple(args, (char *)"O:virConnectListStoragePools", &pyobj_conn))
-        return(NULL);
+        return NULL;
     conn = (virConnectPtr) PyvirConnect_Get(pyobj_conn);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -2675,7 +2675,7 @@ libvirt_virConnectListStoragePools(PyObject *self ATTRIBUTE_UNUSED,
         VIR_FREE(names);
     }

-    return(py_retval);
+    return py_retval;
 }


@@ -2690,7 +2690,7 @@ libvirt_virConnectListDefinedStoragePools(PyObject *self ATTRIBUTE_UNUSED,


     if (!PyArg_ParseTuple(args, (char *)"O:virConnectListDefinedStoragePools", &pyobj_conn))
-        return(NULL);
+        return NULL;
     conn = (virConnectPtr) PyvirConnect_Get(pyobj_conn);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -2728,7 +2728,7 @@ libvirt_virConnectListDefinedStoragePools(PyObject *self ATTRIBUTE_UNUSED,
         VIR_FREE(names);
     }

-    return(py_retval);
+    return py_retval;
 }


@@ -2743,7 +2743,7 @@ libvirt_virStoragePoolListVolumes(PyObject *self ATTRIBUTE_UNUSED,


     if (!PyArg_ParseTuple(args, (char *)"O:virStoragePoolListVolumes", &pyobj_pool))
-        return(NULL);
+        return NULL;
     pool = (virStoragePoolPtr) PyvirStoragePool_Get(pyobj_pool);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -2781,7 +2781,7 @@ libvirt_virStoragePoolListVolumes(PyObject *self ATTRIBUTE_UNUSED,
         VIR_FREE(names);
     }

-    return(py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -2792,7 +2792,7 @@ libvirt_virStoragePoolGetAutostart(PyObject *self ATTRIBUTE_UNUSED, PyObject *ar
     PyObject *pyobj_pool;

     if (!PyArg_ParseTuple(args, (char *)"O:virStoragePoolGetAutostart", &pyobj_pool))
-        return(NULL);
+        return NULL;

     pool = (virStoragePoolPtr) PyvirStoragePool_Get(pyobj_pool);

@@ -2804,7 +2804,7 @@ libvirt_virStoragePoolGetAutostart(PyObject *self ATTRIBUTE_UNUSED, PyObject *ar
         return VIR_PY_NONE;

     py_retval = libvirt_intWrap(autostart);
-    return(py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -2816,7 +2816,7 @@ libvirt_virStoragePoolGetInfo(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
     virStoragePoolInfo info;

     if (!PyArg_ParseTuple(args, (char *)"O:virStoragePoolGetInfo", &pyobj_pool))
-        return(NULL);
+        return NULL;
     pool = (virStoragePoolPtr) PyvirStoragePool_Get(pyobj_pool);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -2835,7 +2835,7 @@ libvirt_virStoragePoolGetInfo(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
                    libvirt_longlongWrap((unsigned long long) info.allocation));
     PyList_SetItem(py_retval, 3,
                    libvirt_longlongWrap((unsigned long long) info.available));
-    return(py_retval);
+    return py_retval;
 }


@@ -2848,7 +2848,7 @@ libvirt_virStorageVolGetInfo(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
     virStorageVolInfo info;

     if (!PyArg_ParseTuple(args, (char *)"O:virStorageVolGetInfo", &pyobj_pool))
-        return(NULL);
+        return NULL;
     pool = (virStorageVolPtr) PyvirStorageVol_Get(pyobj_pool);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -2864,7 +2864,7 @@ libvirt_virStorageVolGetInfo(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
                    libvirt_longlongWrap((unsigned long long) info.capacity));
     PyList_SetItem(py_retval, 2,
                    libvirt_longlongWrap((unsigned long long) info.allocation));
-    return(py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -2876,7 +2876,7 @@ libvirt_virStoragePoolGetUUID(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
     int c_retval;

     if (!PyArg_ParseTuple(args, (char *)"O:virStoragePoolGetUUID", &pyobj_pool))
-        return(NULL);
+        return NULL;
     pool = (virStoragePoolPtr) PyvirStoragePool_Get(pyobj_pool);

     if (pool == NULL)
@@ -2890,7 +2890,7 @@ libvirt_virStoragePoolGetUUID(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {

     py_retval = PyString_FromStringAndSize((char *) &uuid[0], VIR_UUID_BUFLEN);

-    return(py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -2903,7 +2903,7 @@ libvirt_virStoragePoolGetUUIDString(PyObject *self ATTRIBUTE_UNUSED,
     int c_retval;

     if (!PyArg_ParseTuple(args, (char *)"O:virStoragePoolGetUUIDString", &pyobj_pool))
-        return(NULL);
+        return NULL;
     pool = (virStoragePoolPtr) PyvirStoragePool_Get(pyobj_pool);

     if (pool == NULL)
@@ -2916,7 +2916,7 @@ libvirt_virStoragePoolGetUUIDString(PyObject *self ATTRIBUTE_UNUSED,
         return VIR_PY_NONE;

     py_retval = PyString_FromString((char *) &uuidstr[0]);
-    return(py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -2929,7 +2929,7 @@ libvirt_virStoragePoolLookupByUUID(PyObject *self ATTRIBUTE_UNUSED, PyObject *ar
     int len;

     if (!PyArg_ParseTuple(args, (char *)"Oz#:virStoragePoolLookupByUUID", &pyobj_conn, &uuid, &len))
-        return(NULL);
+        return NULL;
     conn = (virConnectPtr) PyvirConnect_Get(pyobj_conn);

     if ((uuid == NULL) || (len != VIR_UUID_BUFLEN))
@@ -2939,7 +2939,7 @@ libvirt_virStoragePoolLookupByUUID(PyObject *self ATTRIBUTE_UNUSED, PyObject *ar
     c_retval = virStoragePoolLookupByUUID(conn, uuid);
     LIBVIRT_END_ALLOW_THREADS;
     py_retval = libvirt_virStoragePoolPtrWrap((virStoragePoolPtr) c_retval);
-    return(py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -2955,7 +2955,7 @@ libvirt_virNodeListDevices(PyObject *self ATTRIBUTE_UNUSED,

     if (!PyArg_ParseTuple(args, (char *)"Ozi:virNodeListDevices",
                           &pyobj_conn, &cap, &flags))
-        return(NULL);
+        return NULL;
     conn = (virConnectPtr) PyvirConnect_Get(pyobj_conn);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -2985,7 +2985,7 @@ libvirt_virNodeListDevices(PyObject *self ATTRIBUTE_UNUSED,
         VIR_FREE(names);
     }

-    return(py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -2998,7 +2998,7 @@ libvirt_virNodeDeviceListCaps(PyObject *self ATTRIBUTE_UNUSED,
     PyObject *pyobj_dev;

     if (!PyArg_ParseTuple(args, (char *)"O:virNodeDeviceListCaps", &pyobj_dev))
-        return(NULL);
+        return NULL;
     dev = (virNodeDevicePtr) PyvirNodeDevice_Get(pyobj_dev);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -3028,7 +3028,7 @@ libvirt_virNodeDeviceListCaps(PyObject *self ATTRIBUTE_UNUSED,
         VIR_FREE(names);
     }

-    return(py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -3040,7 +3040,7 @@ libvirt_virSecretGetUUID(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
     int c_retval;

     if (!PyArg_ParseTuple(args, (char *)"O:virSecretGetUUID", &pyobj_secret))
-        return(NULL);
+        return NULL;
     secret = (virSecretPtr) PyvirSecret_Get(pyobj_secret);

     if (secret == NULL)
@@ -3053,7 +3053,7 @@ libvirt_virSecretGetUUID(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
         return VIR_PY_NONE;
     py_retval = PyString_FromStringAndSize((char *) &uuid[0], VIR_UUID_BUFLEN);

-    return(py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -3067,7 +3067,7 @@ libvirt_virSecretGetUUIDString(PyObject *self ATTRIBUTE_UNUSED,

     if (!PyArg_ParseTuple(args, (char *)"O:virSecretGetUUIDString",
                           &pyobj_dom))
-        return(NULL);
+        return NULL;
     dom = (virSecretPtr) PyvirSecret_Get(pyobj_dom);

     if (dom == NULL)
@@ -3080,7 +3080,7 @@ libvirt_virSecretGetUUIDString(PyObject *self ATTRIBUTE_UNUSED,
         return VIR_PY_NONE;

     py_retval = PyString_FromString((char *) &uuidstr[0]);
-    return(py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -3093,7 +3093,7 @@ libvirt_virSecretLookupByUUID(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
     int len;

     if (!PyArg_ParseTuple(args, (char *)"Oz#:virSecretLookupByUUID", &pyobj_conn, &uuid, &len))
-        return(NULL);
+        return NULL;
     conn = (virConnectPtr) PyvirConnect_Get(pyobj_conn);

     if ((uuid == NULL) || (len != VIR_UUID_BUFLEN))
@@ -3103,7 +3103,7 @@ libvirt_virSecretLookupByUUID(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
     c_retval = virSecretLookupByUUID(conn, uuid);
     LIBVIRT_END_ALLOW_THREADS;
     py_retval = libvirt_virSecretPtrWrap((virSecretPtr) c_retval);
-    return(py_retval);
+    return py_retval;
 }


@@ -3212,7 +3212,7 @@ libvirt_virNWFilterGetUUID(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
     int c_retval;

     if (!PyArg_ParseTuple(args, (char *)"O:virNWFilterGetUUID", &pyobj_nwfilter))
-        return(NULL);
+        return NULL;
     nwfilter = (virNWFilterPtr) PyvirNWFilter_Get(pyobj_nwfilter);

     if (nwfilter == NULL)
@@ -3225,7 +3225,7 @@ libvirt_virNWFilterGetUUID(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
         return VIR_PY_NONE;
     py_retval = PyString_FromStringAndSize((char *) &uuid[0], VIR_UUID_BUFLEN);

-    return(py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -3239,7 +3239,7 @@ libvirt_virNWFilterGetUUIDString(PyObject *self ATTRIBUTE_UNUSED,

     if (!PyArg_ParseTuple(args, (char *)"O:virNWFilterGetUUIDString",
                           &pyobj_nwfilter))
-        return(NULL);
+        return NULL;
     nwfilter = (virNWFilterPtr) PyvirNWFilter_Get(pyobj_nwfilter);

     if (nwfilter == NULL)
@@ -3252,7 +3252,7 @@ libvirt_virNWFilterGetUUIDString(PyObject *self ATTRIBUTE_UNUSED,
         return VIR_PY_NONE;

     py_retval = PyString_FromString((char *) &uuidstr[0]);
-    return(py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -3265,7 +3265,7 @@ libvirt_virNWFilterLookupByUUID(PyObject *self ATTRIBUTE_UNUSED, PyObject *args)
     int len;

     if (!PyArg_ParseTuple(args, (char *)"Oz#:virNWFilterLookupByUUID", &pyobj_conn, &uuid, &len))
-        return(NULL);
+        return NULL;
     conn = (virConnectPtr) PyvirConnect_Get(pyobj_conn);

     if ((uuid == NULL) || (len != VIR_UUID_BUFLEN))
@@ -3275,7 +3275,7 @@ libvirt_virNWFilterLookupByUUID(PyObject *self ATTRIBUTE_UNUSED, PyObject *args)
     c_retval = virNWFilterLookupByUUID(conn, uuid);
     LIBVIRT_END_ALLOW_THREADS;
     py_retval = libvirt_virNWFilterPtrWrap((virNWFilterPtr) c_retval);
-    return(py_retval);
+    return py_retval;
 }


@@ -3333,7 +3333,7 @@ libvirt_virConnectListInterfaces(PyObject *self ATTRIBUTE_UNUSED,


     if (!PyArg_ParseTuple(args, (char *)"O:virConnectListInterfaces", &pyobj_conn))
-        return(NULL);
+        return NULL;
     conn = (virConnectPtr) PyvirConnect_Get(pyobj_conn);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -3371,7 +3371,7 @@ libvirt_virConnectListInterfaces(PyObject *self ATTRIBUTE_UNUSED,
         VIR_FREE(names);
     }

-    return(py_retval);
+    return py_retval;
 }


@@ -3387,7 +3387,7 @@ libvirt_virConnectListDefinedInterfaces(PyObject *self ATTRIBUTE_UNUSED,

     if (!PyArg_ParseTuple(args, (char *)"O:virConnectListDefinedInterfaces",
                           &pyobj_conn))
-        return(NULL);
+        return NULL;
     conn = (virConnectPtr) PyvirConnect_Get(pyobj_conn);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -3425,7 +3425,7 @@ libvirt_virConnectListDefinedInterfaces(PyObject *self ATTRIBUTE_UNUSED,
         VIR_FREE(names);
     }

-    return(py_retval);
+    return py_retval;
 }


@@ -3443,7 +3443,7 @@ libvirt_virConnectBaselineCPU(PyObject *self ATTRIBUTE_UNUSED,

     if (!PyArg_ParseTuple(args, (char *)"OOi:virConnectBaselineCPU",
                           &pyobj_conn, &list, &flags))
-        return(NULL);
+        return NULL;
     conn = (virConnectPtr) PyvirConnect_Get(pyobj_conn);

     if (PyList_Check(list)) {
@@ -3490,7 +3490,7 @@ libvirt_virDomainGetJobInfo(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
     virDomainJobInfo info;

     if (!PyArg_ParseTuple(args, (char *)"O:virDomainGetJobInfo", &pyobj_domain))
-        return(NULL);
+        return NULL;
     domain = (virDomainPtr) PyvirDomain_Get(pyobj_domain);

     LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -3512,7 +3512,7 @@ libvirt_virDomainGetJobInfo(PyObject *self ATTRIBUTE_UNUSED, PyObject *args) {
     PyList_SetItem(py_retval, 10, libvirt_ulonglongWrap(info.fileProcessed));
     PyList_SetItem(py_retval, 11, libvirt_ulonglongWrap(info.fileRemaining));

-    return(py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -3529,7 +3529,7 @@ libvirt_virDomainGetBlockJobInfo(PyObject *self ATTRIBUTE_UNUSED,

     if (!PyArg_ParseTuple(args, (char *)"Ozi:virDomainGetBlockJobInfo",
                           &pyobj_domain, &path, &flags))
-        return(NULL);
+        return NULL;
     domain = (virDomainPtr) PyvirDomain_Get(pyobj_domain);

 LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -3927,7 +3927,7 @@ libvirt_virConnectDomainEventRegister(ATTRIBUTE_UNUSED PyObject * self,
     LIBVIRT_END_ALLOW_THREADS;

     py_retval = libvirt_intWrap(ret);
-    return (py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -3944,7 +3944,7 @@ libvirt_virConnectDomainEventDeregister(ATTRIBUTE_UNUSED PyObject * self,
     if (!PyArg_ParseTuple
         (args, (char *) "OO:virConnectDomainEventDeregister",
          &pyobj_conn, &pyobj_conn_inst))
-        return (NULL);
+        return NULL;

     DEBUG("libvirt_virConnectDomainEventDeregister(%p) called\n", pyobj_conn);

@@ -3958,7 +3958,7 @@ libvirt_virConnectDomainEventDeregister(ATTRIBUTE_UNUSED PyObject * self,

     Py_DECREF(pyobj_conn_inst);
     py_retval = libvirt_intWrap(ret);
-    return (py_retval);
+    return py_retval;
 }

 /*******************************************
@@ -5038,7 +5038,7 @@ libvirt_virConnectDomainEventRegisterAny(ATTRIBUTE_UNUSED PyObject * self,
     }

     py_retval = libvirt_intWrap(ret);
-    return (py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -5054,7 +5054,7 @@ libvirt_virConnectDomainEventDeregisterAny(ATTRIBUTE_UNUSED PyObject * self,
     if (!PyArg_ParseTuple
         (args, (char *) "Oi:virConnectDomainEventDeregister",
          &pyobj_conn, &callbackID))
-        return (NULL);
+        return NULL;

     DEBUG("libvirt_virConnectDomainEventDeregister(%p) called\n", pyobj_conn);

@@ -5066,7 +5066,7 @@ libvirt_virConnectDomainEventDeregisterAny(ATTRIBUTE_UNUSED PyObject * self,

     LIBVIRT_END_ALLOW_THREADS;
     py_retval = libvirt_intWrap(ret);
-    return (py_retval);
+    return py_retval;
 }

 static void
@@ -5271,7 +5271,7 @@ libvirt_virDomainMigrateGetMaxSpeed(PyObject *self ATTRIBUTE_UNUSED, PyObject *a

     if (!PyArg_ParseTuple(args, (char *)"Oi:virDomainMigrateGetMaxSpeed",
                           &pyobj_domain, &flags))
-        return(NULL);
+        return NULL;

     domain = (virDomainPtr) PyvirDomain_Get(pyobj_domain);

@@ -5282,7 +5282,7 @@ libvirt_virDomainMigrateGetMaxSpeed(PyObject *self ATTRIBUTE_UNUSED, PyObject *a
     if (c_retval < 0)
         return VIR_PY_INT_FAIL;
     py_retval = libvirt_ulongWrap(bandwidth);
-    return(py_retval);
+    return py_retval;
 }

 static PyObject *
@@ -5300,7 +5300,7 @@ libvirt_virDomainBlockPeek(PyObject *self ATTRIBUTE_UNUSED,

     if (!PyArg_ParseTuple(args, (char *)"OzLni:virDomainBlockPeek", &pyobj_domain,
                           &disk, &offset, &size, &flags))
-        return(NULL);
+        return NULL;

     domain = (virDomainPtr) PyvirDomain_Get(pyobj_domain);

@@ -5335,7 +5335,7 @@ libvirt_virDomainMemoryPeek(PyObject *self ATTRIBUTE_UNUSED,

     if (!PyArg_ParseTuple(args, (char *)"OLni:virDomainMemoryPeek", &pyobj_domain,
                           &start, &size, &flags))
-        return(NULL);
+        return NULL;

     domain = (virDomainPtr) PyvirDomain_Get(pyobj_domain);

diff --git a/python/libvirt-qemu-override.c b/python/libvirt-qemu-override.c
index c220af1..e532416 100644
--- a/python/libvirt-qemu-override.c
+++ b/python/libvirt-qemu-override.c
@@ -66,7 +66,7 @@ libvirt_qemu_virDomainQemuMonitorCommand(PyObject *self ATTRIBUTE_UNUSED,

     if (!PyArg_ParseTuple(args, (char *)"Ozi:virDomainQemuMonitorCommand",
                           &pyobj_domain, &cmd, &flags))
-        return(NULL);
+        return NULL;
     domain = (virDomainPtr) PyvirDomain_Get(pyobj_domain);

     if (domain == NULL)
@@ -79,7 +79,7 @@ libvirt_qemu_virDomainQemuMonitorCommand(PyObject *self ATTRIBUTE_UNUSED,
         return VIR_PY_NONE;

     py_retval = PyString_FromString(result);
-    return(py_retval);
+    return py_retval;
 }

 /************************************************************************
diff --git a/python/typewrappers.c b/python/typewrappers.c
index 3f200b3..b547cad 100644
--- a/python/typewrappers.c
+++ b/python/typewrappers.c
@@ -43,7 +43,7 @@ libvirt_intWrap(int val)
 {
     PyObject *ret;
     ret = PyInt_FromLong((long) val);
-    return (ret);
+    return ret;
 }

 PyObject *
@@ -51,7 +51,7 @@ libvirt_longWrap(long val)
 {
     PyObject *ret;
     ret = PyInt_FromLong(val);
-    return (ret);
+    return ret;
 }

 PyObject *
@@ -59,7 +59,7 @@ libvirt_ulongWrap(unsigned long val)
 {
     PyObject *ret;
     ret = PyLong_FromLong(val);
-    return (ret);
+    return ret;
 }

 PyObject *
@@ -67,7 +67,7 @@ libvirt_longlongWrap(long long val)
 {
     PyObject *ret;
     ret = PyLong_FromUnsignedLongLong((unsigned long long) val);
-    return (ret);
+    return ret;
 }

 PyObject *
@@ -75,7 +75,7 @@ libvirt_ulonglongWrap(unsigned long long val)
 {
     PyObject *ret;
     ret = PyLong_FromUnsignedLongLong(val);
-    return (ret);
+    return ret;
 }

 PyObject *
@@ -85,11 +85,11 @@ libvirt_charPtrSizeWrap(char *str, Py_ssize_t size)

     if (str == NULL) {
         Py_INCREF(Py_None);
-        return (Py_None);
+        return Py_None;
     }
     ret = PyString_FromStringAndSize(str, size);
     VIR_FREE(str);
-    return (ret);
+    return ret;
 }

 PyObject *
@@ -99,11 +99,11 @@ libvirt_charPtrWrap(char *str)

     if (str == NULL) {
         Py_INCREF(Py_None);
-        return (Py_None);
+        return Py_None;
     }
     ret = PyString_FromString(str);
     VIR_FREE(str);
-    return (ret);
+    return ret;
 }

 PyObject *
@@ -113,10 +113,10 @@ libvirt_constcharPtrWrap(const char *str)

     if (str == NULL) {
         Py_INCREF(Py_None);
-        return (Py_None);
+        return Py_None;
     }
     ret = PyString_FromString(str);
-    return (ret);
+    return ret;
 }

 PyObject *
@@ -126,11 +126,11 @@ libvirt_virDomainPtrWrap(virDomainPtr node)

     if (node == NULL) {
         Py_INCREF(Py_None);
-        return (Py_None);
+        return Py_None;
     }

     ret = libvirt_buildPyObject(node, "virDomainPtr", NULL);
-    return (ret);
+    return ret;
 }

 PyObject *
@@ -140,11 +140,11 @@ libvirt_virNetworkPtrWrap(virNetworkPtr node)

     if (node == NULL) {
         Py_INCREF(Py_None);
-        return (Py_None);
+        return Py_None;
     }

     ret = libvirt_buildPyObject(node, "virNetworkPtr", NULL);
-    return (ret);
+    return ret;
 }

 PyObject *
@@ -154,11 +154,11 @@ libvirt_virInterfacePtrWrap(virInterfacePtr node)

     if (node == NULL) {
         Py_INCREF(Py_None);
-        return (Py_None);
+        return Py_None;
     }

     ret = libvirt_buildPyObject(node, "virInterfacePtr", NULL);
-    return (ret);
+    return ret;
 }

 PyObject *
@@ -168,11 +168,11 @@ libvirt_virStoragePoolPtrWrap(virStoragePoolPtr node)

     if (node == NULL) {
         Py_INCREF(Py_None);
-        return (Py_None);
+        return Py_None;
     }

     ret = libvirt_buildPyObject(node, "virStoragePoolPtr", NULL);
-    return (ret);
+    return ret;
 }

 PyObject *
@@ -182,11 +182,11 @@ libvirt_virStorageVolPtrWrap(virStorageVolPtr node)

     if (node == NULL) {
         Py_INCREF(Py_None);
-        return (Py_None);
+        return Py_None;
     }

     ret = libvirt_buildPyObject(node, "virStorageVolPtr", NULL);
-    return (ret);
+    return ret;
 }

 PyObject *
@@ -196,11 +196,11 @@ libvirt_virConnectPtrWrap(virConnectPtr node)

     if (node == NULL) {
         Py_INCREF(Py_None);
-        return (Py_None);
+        return Py_None;
     }

     ret = libvirt_buildPyObject(node, "virConnectPtr", NULL);
-    return (ret);
+    return ret;
 }

 PyObject *
@@ -210,11 +210,11 @@ libvirt_virNodeDevicePtrWrap(virNodeDevicePtr node)

     if (node == NULL) {
         Py_INCREF(Py_None);
-        return (Py_None);
+        return Py_None;
     }

     ret = libvirt_buildPyObject(node, "virNodeDevicePtr", NULL);
-    return (ret);
+    return ret;
 }

 PyObject *
@@ -228,7 +228,7 @@ libvirt_virSecretPtrWrap(virSecretPtr node)
     }

     ret = libvirt_buildPyObject(node, "virSecretPtr", NULL);
-    return (ret);
+    return ret;
 }

 PyObject *
@@ -242,7 +242,7 @@ libvirt_virNWFilterPtrWrap(virNWFilterPtr node)
     }

     ret = libvirt_buildPyObject(node, "virNWFilterPtr", NULL);
-    return (ret);
+    return ret;
 }

 PyObject *
@@ -256,7 +256,7 @@ libvirt_virStreamPtrWrap(virStreamPtr node)
     }

     ret = libvirt_buildPyObject(node, "virStreamPtr", NULL);
-    return (ret);
+    return ret;
 }

 PyObject *
@@ -266,11 +266,11 @@ libvirt_virDomainSnapshotPtrWrap(virDomainSnapshotPtr node)

     if (node == NULL) {
         Py_INCREF(Py_None);
-        return (Py_None);
+        return Py_None;
     }

     ret = libvirt_buildPyObject(node, "virDomainSnapshotPtr", NULL);
-    return (ret);
+    return ret;
 }

 PyObject *
@@ -281,11 +281,11 @@ libvirt_virEventHandleCallbackWrap(virEventHandleCallback node)
     if (node == NULL) {
         Py_INCREF(Py_None);
         printf("%s: WARNING - Wrapping None\n", __func__);
-        return (Py_None);
+        return Py_None;
     }

     ret = libvirt_buildPyObject(node, "virEventHandleCallback", NULL);
-    return (ret);
+    return ret;
 }

 PyObject *
@@ -296,11 +296,11 @@ libvirt_virEventTimeoutCallbackWrap(virEventTimeoutCallback node)
     if (node == NULL) {
         printf("%s: WARNING - Wrapping None\n", __func__);
         Py_INCREF(Py_None);
-        return (Py_None);
+        return Py_None;
     }

     ret = libvirt_buildPyObject(node, "virEventTimeoutCallback", NULL);
-    return (ret);
+    return ret;
 }

 PyObject *
@@ -310,11 +310,11 @@ libvirt_virFreeCallbackWrap(virFreeCallback node)

     if (node == NULL) {
         Py_INCREF(Py_None);
-        return (Py_None);
+        return Py_None;
     }

     ret = libvirt_buildPyObject(node, "virFreeCallback", NULL);
-    return (ret);
+    return ret;
 }

 PyObject *
@@ -324,9 +324,9 @@ libvirt_virVoidPtrWrap(void* node)

     if (node == NULL) {
         Py_INCREF(Py_None);
-        return (Py_None);
+        return Py_None;
     }

     ret = libvirt_buildPyObject(node, "void*", NULL);
-    return (ret);
+    return ret;
 }
diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c
index d5def1c..903ccd8 100644
--- a/src/conf/domain_conf.c
+++ b/src/conf/domain_conf.c
@@ -6386,12 +6386,12 @@ virSysinfoParseXML(const xmlNodePtr node,
     if (!xmlStrEqual(node->name, BAD_CAST "sysinfo")) {
         virDomainReportError(VIR_ERR_XML_ERROR, "%s",
                         _("XML does not contain expected 'sysinfo' element"));
-        return(NULL);
+        return NULL;
     }

     if (VIR_ALLOC(def) < 0) {
         virReportOOMError();
-        return(NULL);
+        return NULL;
     }

     type = virXMLPropString(node, "type");
@@ -6435,7 +6435,7 @@ virSysinfoParseXML(const xmlNodePtr node,

 cleanup:
     VIR_FREE(type);
-    return(def);
+    return def;

 error:
     virSysinfoDefFree(def);
@@ -6521,7 +6521,7 @@ virDomainVideoAccelDefParseXML(const xmlNodePtr node) {
     }

     if ((support3d == NULL) && (support2d == NULL))
-        return(NULL);
+        return NULL;

     if (VIR_ALLOC(def) < 0) {
         virReportOOMError();
@@ -10128,16 +10128,16 @@ virDomainCpuNumberParse(const char **str, int maxcpu)
     const char *cur = *str;

     if (!c_isdigit(*cur))
-        return (-1);
+        return -1;

     while (c_isdigit(*cur)) {
         ret = ret * 10 + (*cur - '0');
         if (ret >= maxcpu)
-            return (-1);
+            return -1;
         cur++;
     }
     *str = cur;
-    return (ret);
+    return ret;
 }

 /**
@@ -10159,7 +10159,7 @@ virDomainCpuSetFormat(char *cpuset, int maxcpu)
     int first = 1;

     if ((cpuset == NULL) || (maxcpu <= 0) || (maxcpu > 100000))
-        return (NULL);
+        return NULL;

     cur = 0;
     start = -1;
@@ -10224,7 +10224,7 @@ virDomainCpuSetParse(const char *str, char sep,

     if ((str == NULL) || (cpuset == NULL) || (maxcpu <= 0) ||
         (maxcpu > 100000))
-        return (-1);
+        return -1;

     cur = str;
     virSkipSpaces(&cur);
@@ -10291,12 +10291,12 @@ virDomainCpuSetParse(const char *str, char sep,
         } else
             goto parse_error;
     }
-    return (ret);
+    return ret;

   parse_error:
     virDomainReportError(VIR_ERR_INTERNAL_ERROR,
                          "%s", _("topology cpuset syntax error"));
-    return (-1);
+    return -1;
 }


diff --git a/src/conf/interface_conf.c b/src/conf/interface_conf.c
index 59f74a1..5601d3b 100644
--- a/src/conf/interface_conf.c
+++ b/src/conf/interface_conf.c
@@ -124,10 +124,10 @@ virInterfaceDefParseName(virInterfaceDefPtr def,
     if (tmp == NULL) {
         virInterfaceReportError(VIR_ERR_XML_ERROR,
                                 "%s",  _("interface has no name"));
-        return(-1);
+        return -1;
     }
     def->name = tmp;
-    return(0);
+    return 0;
 }

 static int
@@ -140,11 +140,11 @@ virInterfaceDefParseMtu(virInterfaceDefPtr def,
     if ((ret == -2) || ((ret == 0) && (mtu > 100000))) {
         virInterfaceReportError(VIR_ERR_XML_ERROR,
                          "%s", _("interface mtu value is improper"));
-        return(-1);
+        return -1;
     } else if (ret == 0) {
         def->mtu = (unsigned int) mtu;
     }
-    return(0);
+    return 0;
 }

 static int
@@ -165,10 +165,10 @@ virInterfaceDefParseStartMode(virInterfaceDefPtr def,
         virInterfaceReportError(VIR_ERR_XML_ERROR,
                                 _("unknown interface startmode %s"), tmp);
         VIR_FREE(tmp);
-        return(-1);
+        return -1;
     }
     VIR_FREE(tmp);
-    return(0);
+    return 0;
 }

 static int
@@ -178,7 +178,7 @@ virInterfaceDefParseBondMode(xmlXPathContextPtr ctxt) {

     tmp = virXPathString("string(./@mode)", ctxt);
     if (tmp == NULL)
-        return(VIR_INTERFACE_BOND_NONE);
+        return VIR_INTERFACE_BOND_NONE;
     if (STREQ(tmp, "balance-rr"))
         ret = VIR_INTERFACE_BOND_BALRR;
     else if (STREQ(tmp, "active-backup"))
@@ -199,7 +199,7 @@ virInterfaceDefParseBondMode(xmlXPathContextPtr ctxt) {
         ret = -1;
     }
     VIR_FREE(tmp);
-    return(ret);
+    return ret;
 }

 static int
@@ -209,7 +209,7 @@ virInterfaceDefParseBondMiiCarrier(xmlXPathContextPtr ctxt) {

     tmp = virXPathString("string(./miimon/@carrier)", ctxt);
     if (tmp == NULL)
-        return(VIR_INTERFACE_BOND_MII_NONE);
+        return VIR_INTERFACE_BOND_MII_NONE;
     if (STREQ(tmp, "ioctl"))
         ret = VIR_INTERFACE_BOND_MII_IOCTL;
     else if (STREQ(tmp, "netif"))
@@ -220,7 +220,7 @@ virInterfaceDefParseBondMiiCarrier(xmlXPathContextPtr ctxt) {
         ret = -1;
     }
     VIR_FREE(tmp);
-    return(ret);
+    return ret;
 }

 static int
@@ -230,7 +230,7 @@ virInterfaceDefParseBondArpValid(xmlXPathContextPtr ctxt) {

     tmp = virXPathString("string(./arpmon/@validate)", ctxt);
     if (tmp == NULL)
-        return(VIR_INTERFACE_BOND_ARP_NONE);
+        return VIR_INTERFACE_BOND_ARP_NONE;
     if (STREQ(tmp, "active"))
         ret = VIR_INTERFACE_BOND_ARP_ACTIVE;
     else if (STREQ(tmp, "backup"))
@@ -243,7 +243,7 @@ virInterfaceDefParseBondArpValid(xmlXPathContextPtr ctxt) {
         ret = -1;
     }
     VIR_FREE(tmp);
-    return(ret);
+    return ret;
 }

 static int
@@ -273,7 +273,7 @@ virInterfaceDefParseDhcp(virInterfaceProtocolDefPtr def,
         def->peerdns = -1;

     ctxt->node = save;
-    return(ret);
+    return ret;
 }

 static int
@@ -292,11 +292,11 @@ virInterfaceDefParseIp(virInterfaceIpDefPtr def,
         else if (ret == -2) {
             virInterfaceReportError(VIR_ERR_XML_ERROR,
                               "%s", _("Invalid ip address prefix value"));
-            return(-1);
+            return -1;
         }
     }

-    return(0);
+    return 0;
 }

 static int
@@ -314,7 +314,7 @@ virInterfaceDefParseProtoIPv4(virInterfaceProtocolDefPtr def,
     if (dhcp != NULL) {
         ret = virInterfaceDefParseDhcp(def, dhcp, ctxt);
         if (ret != 0)
-           return(ret);
+           return ret;
     }

     nIpNodes = virXPathNodeSet("./ip", ctxt, &ipNodes);
@@ -351,7 +351,7 @@ virInterfaceDefParseProtoIPv4(virInterfaceProtocolDefPtr def,

 error:
     VIR_FREE(ipNodes);
-    return(ret);
+    return ret;
 }

 static int
@@ -373,7 +373,7 @@ virInterfaceDefParseProtoIPv6(virInterfaceProtocolDefPtr def,
     if (dhcp != NULL) {
         ret = virInterfaceDefParseDhcp(def, dhcp, ctxt);
         if (ret != 0)
-           return(ret);
+           return ret;
     }

     nIpNodes = virXPathNodeSet("./ip", ctxt, &ipNodes);
@@ -410,7 +410,7 @@ virInterfaceDefParseProtoIPv6(virInterfaceProtocolDefPtr def,

 error:
     VIR_FREE(ipNodes);
-    return(ret);
+    return ret;
 }

 static int
@@ -482,7 +482,7 @@ virInterfaceDefParseIfAdressing(virInterfaceDefPtr def,
 error:
     VIR_FREE(protoNodes);
     ctxt->node = save;
-    return(ret);
+    return ret;

 }

@@ -524,7 +524,7 @@ virInterfaceDefParseBridge(virInterfaceDefPtr def,
 error:
     VIR_FREE(interfaces);
     ctxt->node = bridge;
-    return(ret);
+    return ret;
 }

 static int
@@ -570,7 +570,7 @@ virInterfaceDefParseBondItfs(virInterfaceDefPtr def,
 error:
     VIR_FREE(interfaces);
     ctxt->node = bond;
-    return(ret);
+    return ret;
 }

 static int
@@ -650,7 +650,7 @@ virInterfaceDefParseBond(virInterfaceDefPtr def,
         }
     }
 error:
-    return(ret);
+    return ret;
 }

 static int
@@ -660,7 +660,7 @@ virInterfaceDefParseVlan(virInterfaceDefPtr def,
     if (def->data.vlan.tag == NULL) {
         virInterfaceReportError(VIR_ERR_XML_ERROR,
                     "%s", _("vlan interface misses the tag attribute"));
-        return(-1);
+        return -1;
     }

     def->data.vlan.devname =
@@ -668,9 +668,9 @@ virInterfaceDefParseVlan(virInterfaceDefPtr def,
     if (def->data.vlan.devname == NULL) {
         virInterfaceReportError(VIR_ERR_XML_ERROR,
                     "%s", _("vlan interface misses name attribute"));
-        return(-1);
+        return -1;
     }
-    return(0);
+    return 0;
 }

 static virInterfaceDefPtr
@@ -685,14 +685,14 @@ virInterfaceDefParseXML(xmlXPathContextPtr ctxt, int parentIfType) {
     if (tmp == NULL) {
         virInterfaceReportError(VIR_ERR_XML_ERROR,
                                 "%s", _("interface misses the type attribute"));
-        return(NULL);
+        return NULL;
     }
     type = virInterfaceTypeFromString(tmp);
     if (type == -1) {
         virInterfaceReportError(VIR_ERR_XML_ERROR,
                                 _("unknown interface type %s"), tmp);
         VIR_FREE(tmp);
-        return(NULL);
+        return NULL;
     }
     VIR_FREE(tmp);

@@ -906,7 +906,7 @@ virInterfaceBridgeDefFormat(virBufferPtr buf,
     }

     virBufferAsprintf(buf, "%*s  </bridge>\n", level*2, "");
-    return(ret);
+    return ret;
 }

 static int
@@ -948,7 +948,7 @@ virInterfaceBondDefFormat(virBufferPtr buf,
         if (def->data.bond.target == NULL) {
             virInterfaceReportError(VIR_ERR_INTERNAL_ERROR,
                           "%s", _("bond arp monitoring has no target"));
-            return(-1);
+            return -1;
         }
         virBufferAsprintf(buf, "%*s    <arpmon interval='%d' target='%s'",
                           level*2, "",
@@ -967,7 +967,7 @@ virInterfaceBondDefFormat(virBufferPtr buf,
     }

     virBufferAsprintf(buf, "%*s  </bond>\n", level*2, "");
-    return(ret);
+    return ret;
 }

 static int
@@ -976,7 +976,7 @@ virInterfaceVlanDefFormat(virBufferPtr buf,
     if (def->data.vlan.tag == NULL) {
         virInterfaceReportError(VIR_ERR_INTERNAL_ERROR,
                                 "%s", _("vlan misses the tag name"));
-        return(-1);
+        return -1;
     }

     virBufferAsprintf(buf, "%*s  <vlan tag='%s'",
@@ -988,7 +988,7 @@ virInterfaceVlanDefFormat(virBufferPtr buf,
         virBufferAsprintf(buf, "%*s  </vlan>\n", level*2, "");
     } else
         virBufferAddLit(buf, "/>\n");
-    return(0);
+    return 0;
 }

 static int
@@ -1035,7 +1035,7 @@ virInterfaceProtocolDefFormat(virBufferPtr buf, const virInterfaceDefPtr def,

         virBufferAsprintf(buf, "%*s  </protocol>\n", level*2, "");
     }
-    return(0);
+    return 0;
 }

 static int
@@ -1061,7 +1061,7 @@ virInterfaceStartmodeDefFormat(virBufferPtr buf,
             return -1;
     }
     virBufferAsprintf(buf, "%*s  <start mode='%s'/>\n", level*2, "", mode);
-    return(0);
+    return 0;
 }

 static int
diff --git a/src/conf/nwfilter_params.c b/src/conf/nwfilter_params.c
index 7400fa0..3ad4bed 100644
--- a/src/conf/nwfilter_params.c
+++ b/src/conf/nwfilter_params.c
@@ -908,7 +908,7 @@ virNWFilterVarAccessEqual(const virNWFilterVarAccessPtr a,
                 a->u.index.intIterId == b->u.index.intIterId);
         break;
     case VIR_NWFILTER_VAR_ACCESS_ITERATOR:
-        return (a->u.iterId == b->u.iterId);
+        return a->u.iterId == b->u.iterId;
         break;
     case VIR_NWFILTER_VAR_ACCESS_LAST:
         break;
diff --git a/src/cpu/cpu_x86.c b/src/cpu/cpu_x86.c
index 308604b..8d92649 100644
--- a/src/cpu/cpu_x86.c
+++ b/src/cpu/cpu_x86.c
@@ -392,7 +392,7 @@ x86DataIsEmpty(union cpuData *data)
 {
     struct data_iterator iter = DATA_ITERATOR_INIT(data);

-    return (x86DataCpuidNext(&iter) == NULL);
+    return x86DataCpuidNext(&iter) == NULL;
 }


diff --git a/src/datatypes.c b/src/datatypes.c
index f0b5025..75a3f07 100644
--- a/src/datatypes.c
+++ b/src/datatypes.c
@@ -70,14 +70,14 @@ virGetConnect(void) {
     ret->interfacePrivateData = NULL;

     ret->refs = 1;
-    return(ret);
+    return ret;

 failed:
     if (ret != NULL) {
         virMutexDestroy(&ret->lock);
         VIR_FREE(ret);
     }
-    return(NULL);
+    return NULL;
 }

 /**
@@ -148,10 +148,10 @@ virUnrefConnect(virConnectPtr conn) {
     if (refs == 0) {
         virReleaseConnect(conn);
         /* Already unlocked mutex */
-        return (0);
+        return 0;
     }
     virMutexUnlock(&conn->lock);
-    return (refs);
+    return refs;
 }

 /**
@@ -207,14 +207,14 @@ virGetDomain(virConnectPtr conn, const char *name, const unsigned char *uuid) {
     conn->refs++;
     ret->refs++;
     virMutexUnlock(&conn->lock);
-    return(ret);
+    return ret;

  error:
     if (ret != NULL) {
         VIR_FREE(ret->name);
         VIR_FREE(ret);
     }
-    return(NULL);
+    return NULL;
 }

 /**
@@ -279,11 +279,11 @@ virUnrefDomain(virDomainPtr domain) {
     if (refs == 0) {
         virReleaseDomain(domain);
         /* Already unlocked mutex */
-        return (0);
+        return 0;
     }

     virMutexUnlock(&domain->conn->lock);
-    return (refs);
+    return refs;
 }

 /**
@@ -338,14 +338,14 @@ virGetNetwork(virConnectPtr conn, const char *name, const unsigned char *uuid) {
     conn->refs++;
     ret->refs++;
     virMutexUnlock(&conn->lock);
-    return(ret);
+    return ret;

  error:
     if (ret != NULL) {
         VIR_FREE(ret->name);
         VIR_FREE(ret);
     }
-    return(NULL);
+    return NULL;
 }

 /**
@@ -410,11 +410,11 @@ virUnrefNetwork(virNetworkPtr network) {
     if (refs == 0) {
         virReleaseNetwork(network);
         /* Already unlocked mutex */
-        return (0);
+        return 0;
     }

     virMutexUnlock(&network->conn->lock);
-    return (refs);
+    return refs;
 }


@@ -475,7 +475,7 @@ virGetInterface(virConnectPtr conn, const char *name, const char *mac) {
     conn->refs++;
     ret->refs++;
     virMutexUnlock(&conn->lock);
-    return(ret);
+    return ret;

  error:
     if (ret != NULL) {
@@ -483,7 +483,7 @@ virGetInterface(virConnectPtr conn, const char *name, const char *mac) {
         VIR_FREE(ret->mac);
         VIR_FREE(ret);
     }
-    return(NULL);
+    return NULL;
 }

 /**
@@ -546,11 +546,11 @@ virUnrefInterface(virInterfacePtr iface) {
     if (refs == 0) {
         virReleaseInterface(iface);
         /* Already unlocked mutex */
-        return (0);
+        return 0;
     }

     virMutexUnlock(&iface->conn->lock);
-    return (refs);
+    return refs;
 }


@@ -607,14 +607,14 @@ virGetStoragePool(virConnectPtr conn, const char *name,
     conn->refs++;
     ret->refs++;
     virMutexUnlock(&conn->lock);
-    return(ret);
+    return ret;

 error:
     if (ret != NULL) {
         VIR_FREE(ret->name);
         VIR_FREE(ret);
     }
-    return(NULL);
+    return NULL;
 }


@@ -680,11 +680,11 @@ virUnrefStoragePool(virStoragePoolPtr pool) {
     if (refs == 0) {
         virReleaseStoragePool(pool);
         /* Already unlocked mutex */
-        return (0);
+        return 0;
     }

     virMutexUnlock(&pool->conn->lock);
-    return (refs);
+    return refs;
 }


@@ -750,7 +750,7 @@ virGetStorageVol(virConnectPtr conn, const char *pool, const char *name,
     conn->refs++;
     ret->refs++;
     virMutexUnlock(&conn->lock);
-    return(ret);
+    return ret;

 error:
     if (ret != NULL) {
@@ -759,7 +759,7 @@ error:
         VIR_FREE(ret->pool);
         VIR_FREE(ret);
     }
-    return(NULL);
+    return NULL;
 }


@@ -824,11 +824,11 @@ virUnrefStorageVol(virStorageVolPtr vol) {
     if (refs == 0) {
         virReleaseStorageVol(vol);
         /* Already unlocked mutex */
-        return (0);
+        return 0;
     }

     virMutexUnlock(&vol->conn->lock);
-    return (refs);
+    return refs;
 }


@@ -876,14 +876,14 @@ virGetNodeDevice(virConnectPtr conn, const char *name)
     conn->refs++;
     ret->refs++;
     virMutexUnlock(&conn->lock);
-    return(ret);
+    return ret;

 error:
     if (ret != NULL) {
         VIR_FREE(ret->name);
         VIR_FREE(ret);
     }
-    return(NULL);
+    return NULL;
 }


@@ -942,11 +942,11 @@ virUnrefNodeDevice(virNodeDevicePtr dev) {
     if (refs == 0) {
         virReleaseNodeDevice(dev);
         /* Already unlocked mutex */
-        return (0);
+        return 0;
     }

     virMutexUnlock(&dev->conn->lock);
-    return (refs);
+    return refs;
 }


@@ -1092,12 +1092,12 @@ virStreamPtr virGetStream(virConnectPtr conn) {
     conn->refs++;
     ret->refs++;
     virMutexUnlock(&conn->lock);
-    return(ret);
+    return ret;

 error:
     virMutexUnlock(&conn->lock);
     VIR_FREE(ret);
-    return(NULL);
+    return NULL;
 }

 static void
@@ -1129,11 +1129,11 @@ int virUnrefStream(virStreamPtr st) {
     if (refs == 0) {
         virReleaseStream(st);
         /* Already unlocked mutex */
-        return (0);
+        return 0;
     }

     virMutexUnlock(&st->conn->lock);
-    return (refs);
+    return refs;
 }


@@ -1189,14 +1189,14 @@ virGetNWFilter(virConnectPtr conn, const char *name, const unsigned char *uuid)
     conn->refs++;
     ret->refs++;
     virMutexUnlock(&conn->lock);
-    return(ret);
+    return ret;

 error:
     if (ret != NULL) {
         VIR_FREE(ret->name);
         VIR_FREE(ret);
     }
-    return(NULL);
+    return NULL;
 }


@@ -1265,11 +1265,11 @@ virUnrefNWFilter(virNWFilterPtr nwfilter)
     if (refs == 0) {
         virReleaseNWFilter(nwfilter);
         /* Already unlocked mutex */
-        return (0);
+        return 0;
     }

     virMutexUnlock(&nwfilter->conn->lock);
-    return (refs);
+    return refs;
 }


@@ -1305,14 +1305,14 @@ virGetDomainSnapshot(virDomainPtr domain, const char *name)
     domain->refs++;
     ret->refs++;
     virMutexUnlock(&domain->conn->lock);
-    return(ret);
+    return ret;

  error:
     if (ret != NULL) {
         VIR_FREE(ret->name);
         VIR_FREE(ret);
     }
-    return(NULL);
+    return NULL;
 }


@@ -1355,9 +1355,9 @@ virUnrefDomainSnapshot(virDomainSnapshotPtr snapshot)
     if (refs == 0) {
         virReleaseDomainSnapshot(snapshot);
         /* Already unlocked mutex */
-        return (0);
+        return 0;
     }

     virMutexUnlock(&snapshot->domain->conn->lock);
-    return (refs);
+    return refs;
 }
diff --git a/src/interface/netcf_driver.c b/src/interface/netcf_driver.c
index 2f322b4..45e6442 100644
--- a/src/interface/netcf_driver.c
+++ b/src/interface/netcf_driver.c
@@ -73,7 +73,7 @@ static int netcf_to_vir_err(int netcf_errcode)
              * allocation failed return VIR ERR NO MEMORY
              * though it should not be used now.
              */
-            return(2);
+            return 2;
         case NETCF_EXMLPARSER:
             /* XML parser choked */
             return VIR_ERR_XML_ERROR;
diff --git a/src/lxc/lxc_driver.c b/src/lxc/lxc_driver.c
index 3af8084..d811e01 100644
--- a/src/lxc/lxc_driver.c
+++ b/src/lxc/lxc_driver.c
@@ -2702,7 +2702,7 @@ lxcReload(void) {
 static int lxcShutdown(void)
 {
     if (lxc_driver == NULL)
-        return(-1);
+        return -1;

     lxcDriverLock(lxc_driver);
     virDomainObjListDeinit(&lxc_driver->domains);
@@ -2735,7 +2735,7 @@ lxcActive(void) {
     int active;

     if (lxc_driver == NULL)
-        return(0);
+        return 0;

     lxcDriverLock(lxc_driver);
     active = virDomainObjListNumOfDomains(&lxc_driver->domains, 1);
diff --git a/src/nwfilter/nwfilter_ebiptables_driver.c b/src/nwfilter/nwfilter_ebiptables_driver.c
index 0db9f19..624edbe 100644
--- a/src/nwfilter/nwfilter_ebiptables_driver.c
+++ b/src/nwfilter/nwfilter_ebiptables_driver.c
@@ -3097,7 +3097,7 @@ ebiptablesInstCommand(virBufferPtr buf,
  */
 static int
 ebiptablesCanApplyBasicRules(void) {
-    return (ebtables_cmd_path != NULL);
+    return ebtables_cmd_path != NULL;
 }

 /**
@@ -3445,7 +3445,7 @@ ebiptablesRuleOrderSort(const void *a, const void *b)
     }
 normal:
     /* priorities are limited to range [-1000, 1000] */
-    return (insta->priority - instb->priority);
+    return insta->priority - instb->priority;
 }

 static int
diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c
index 3b9eec8..0f9235a 100644
--- a/src/qemu/qemu_command.c
+++ b/src/qemu/qemu_command.c
@@ -3471,7 +3471,7 @@ static char *qemuBuildSmbiosBiosStr(virSysinfoDefPtr def)

     if ((def->bios_vendor == NULL) && (def->bios_version == NULL) &&
         (def->bios_date == NULL) && (def->bios_release == NULL))
-        return(NULL);
+        return NULL;

     virBufferAddLit(&buf, "type=0");

@@ -3497,7 +3497,7 @@ static char *qemuBuildSmbiosBiosStr(virSysinfoDefPtr def)

 error:
     virBufferFreeAndReset(&buf);
-    return(NULL);
+    return NULL;
 }

 static char *qemuBuildSmbiosSystemStr(virSysinfoDefPtr def, bool skip_uuid)
@@ -3544,7 +3544,7 @@ static char *qemuBuildSmbiosSystemStr(virSysinfoDefPtr def, bool skip_uuid)

 error:
     virBufferFreeAndReset(&buf);
-    return(NULL);
+    return NULL;
 }

 static char *
diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c
index b00257b..36d8ad0 100644
--- a/src/qemu/qemu_driver.c
+++ b/src/qemu/qemu_driver.c
@@ -2803,10 +2803,10 @@ qemuDomainManagedSavePath(struct qemud_driver *driver, virDomainObjPtr vm) {

     if (virAsprintf(&ret, "%s/%s.save", driver->saveDir, vm->def->name) < 0) {
         virReportOOMError();
-        return(NULL);
+        return NULL;
     }

-    return(ret);
+    return ret;
 }

 static int
diff --git a/src/qemu/qemu_process.c b/src/qemu/qemu_process.c
index 8915a9a..744c5ad 100644
--- a/src/qemu/qemu_process.c
+++ b/src/qemu/qemu_process.c
@@ -87,7 +87,7 @@ qemuProcessRemoveDomainStatus(struct qemud_driver *driver,

     if (virAsprintf(&file, "%s/%s.xml", driver->stateDir, vm->def->name) < 0) {
         virReportOOMError();
-        return(-1);
+        return -1;
     }

     if (unlink(file) < 0 && errno != ENOENT && errno != ENOTDIR)
diff --git a/src/remote/remote_driver.c b/src/remote/remote_driver.c
index 4ddebcb..906ae4b 100644
--- a/src/remote/remote_driver.c
+++ b/src/remote/remote_driver.c
@@ -183,7 +183,7 @@ remoteFindDaemonPath(void)
     const char *customDaemon = getenv("LIBVIRTD_PATH");

     if (customDaemon)
-        return(customDaemon);
+        return customDaemon;

     for (i = 0; serverPaths[i]; i++) {
         if (virFileIsExecutable(serverPaths[i])) {
diff --git a/src/security/security_selinux.c b/src/security/security_selinux.c
index d5f35dd..1e27e10 100644
--- a/src/security/security_selinux.c
+++ b/src/security/security_selinux.c
@@ -105,7 +105,7 @@ SELinuxGenNewContext(const char *oldcontext, const char *mcs)
     context_free(con);
 err:
     freecon(scontext);
-    return (newcontext);
+    return newcontext;
 }

 static int
diff --git a/src/test/test_driver.c b/src/test/test_driver.c
index f03b2fd..1587958 100644
--- a/src/test/test_driver.c
+++ b/src/test/test_driver.c
@@ -641,7 +641,7 @@ static char *testBuildFilename(const char *relativeTo,
     char *offset;
     int baseLen;
     if (!filename || filename[0] == '\0')
-        return (NULL);
+        return NULL;
     if (filename[0] == '/')
         return strdup(filename);

@@ -1078,7 +1078,7 @@ static int testOpenFromFile(virConnectPtr conn,
     xmlFreeDoc(xml);
     testDriverUnlock(privconn);

-    return (0);
+    return 0;

  error:
     xmlXPathFreeContext(ctxt);
@@ -1176,7 +1176,7 @@ static int testGetVersion(virConnectPtr conn ATTRIBUTE_UNUSED,
                           unsigned long *hvVer)
 {
     *hvVer = 2;
-    return (0);
+    return 0;
 }

 static int testIsSecure(virConnectPtr conn ATTRIBUTE_UNUSED)
@@ -1207,7 +1207,7 @@ static int testNodeGetInfo(virConnectPtr conn,
     testDriverLock(privconn);
     memcpy(info, &privconn->nodeInfo, sizeof(virNodeInfo));
     testDriverUnlock(privconn);
-    return (0);
+    return 0;
 }

 static char *testGetCapabilities (virConnectPtr conn)
diff --git a/src/util/conf.c b/src/util/conf.c
index 3370337..b9392f7 100644
--- a/src/util/conf.c
+++ b/src/util/conf.c
@@ -162,12 +162,12 @@ virConfNew(void)

     if (VIR_ALLOC(ret) < 0) {
         virReportOOMError();
-        return(NULL);
+        return NULL;
     }
     ret->filename = NULL;
     ret->flags = 0;

-    return(ret);
+    return ret;
 }

 /**
@@ -187,7 +187,7 @@ virConfCreate(const char *filename, unsigned int flags)
         ret->filename = filename;
         ret->flags = flags;
     }
-    return(ret);
+    return ret;
 }

 /**
@@ -208,13 +208,13 @@ virConfAddEntry(virConfPtr conf, char *name, virConfValuePtr value, char *comm)
     virConfEntryPtr ret, prev;

     if (conf == NULL)
-        return(NULL);
+        return NULL;
     if ((comm == NULL) && (name == NULL))
-        return(NULL);
+        return NULL;

     if (VIR_ALLOC(ret) < 0) {
         virReportOOMError();
-        return(NULL);
+        return NULL;
     }

     ret->name = name;
@@ -229,7 +229,7 @@ virConfAddEntry(virConfPtr conf, char *name, virConfValuePtr value, char *comm)
             prev = prev->next;
         prev->next = ret;
     }
-    return(ret);
+    return ret;
 }

 /************************************************************************
@@ -251,10 +251,10 @@ static int
 virConfSaveValue(virBufferPtr buf, virConfValuePtr val)
 {
     if (val == NULL)
-        return(-1);
+        return -1;
     switch (val->type) {
         case VIR_CONF_NONE:
-            return(-1);
+            return -1;
         case VIR_CONF_LONG:
             virBufferAsprintf(buf, "%ld", val->l);
             break;
@@ -287,9 +287,9 @@ virConfSaveValue(virBufferPtr buf, virConfValuePtr val)
             break;
         }
         default:
-            return(-1);
+            return -1;
     }
-    return(0);
+    return 0;
 }

 /**
@@ -317,7 +317,7 @@ virConfSaveEntry(virBufferPtr buf, virConfEntryPtr cur)
         virBufferAdd(buf, cur->comment, -1);
     }
     virBufferAddLit(buf, "\n");
-    return(0);
+    return 0;
 }

 /************************************************************************
@@ -349,7 +349,7 @@ virConfParseLong(virConfParserCtxtPtr ctxt, long *val)
     }
     if ((ctxt->cur >= ctxt->end) || (!c_isdigit(CUR))) {
         virConfError(ctxt, VIR_ERR_CONF_SYNTAX, _("unterminated number"));
-        return(-1);
+        return -1;
     }
     while ((ctxt->cur < ctxt->end) && (c_isdigit(CUR))) {
         l = l * 10 + (CUR - '0');
@@ -358,7 +358,7 @@ virConfParseLong(virConfParserCtxtPtr ctxt, long *val)
     if (neg)
         l = -l;
     *val = l;
-    return(0);
+    return 0;
 }

 /**
@@ -382,7 +382,7 @@ virConfParseString(virConfParserCtxtPtr ctxt)
             NEXT;
         if (CUR != '\'') {
             virConfError(ctxt, VIR_ERR_CONF_SYNTAX, _("unterminated string"));
-            return(NULL);
+            return NULL;
         }
         ret = strndup(base, ctxt->cur - base);
         if (ret == NULL) {
@@ -406,7 +406,7 @@ virConfParseString(virConfParserCtxtPtr ctxt)

         if (!STRPREFIX(ctxt->cur, "\"\"\"")) {
             virConfError(ctxt, VIR_ERR_CONF_SYNTAX, _("unterminated string"));
-            return(NULL);
+            return NULL;
         }
         ret = strndup(base, ctxt->cur - base);
         if (ret == NULL) {
@@ -421,7 +421,7 @@ virConfParseString(virConfParserCtxtPtr ctxt)
             NEXT;
         if (CUR != '"') {
             virConfError(ctxt, VIR_ERR_CONF_SYNTAX, _("unterminated string"));
-            return(NULL);
+            return NULL;
         }
         ret = strndup(base, ctxt->cur - base);
         if (ret == NULL) {
@@ -430,7 +430,7 @@ virConfParseString(virConfParserCtxtPtr ctxt)
         }
         NEXT;
     }
-    return(ret);
+    return ret;
 }

 /**
@@ -452,25 +452,25 @@ virConfParseValue(virConfParserCtxtPtr ctxt)
     SKIP_BLANKS;
     if (ctxt->cur >= ctxt->end) {
         virConfError(ctxt, VIR_ERR_CONF_SYNTAX, _("expecting a value"));
-        return(NULL);
+        return NULL;
     }
     if ((CUR == '"') || (CUR == '\'')) {
         type = VIR_CONF_STRING;
         str = virConfParseString(ctxt);
         if (str == NULL)
-            return(NULL);
+            return NULL;
     } else if (CUR == '[') {
         if (ctxt->conf->flags & VIR_CONF_FLAG_VMX_FORMAT) {
             virConfError(ctxt, VIR_ERR_CONF_SYNTAX,
                          _("lists not allowed in VMX format"));
-            return(NULL);
+            return NULL;
         }
         type = VIR_CONF_LIST;
         NEXT;
         SKIP_BLANKS_AND_EOL;
         if ((ctxt->cur < ctxt->end) && (CUR != ']')) {
             if ((lst = virConfParseValue(ctxt)) == NULL)
-                return(NULL);
+                return NULL;
             SKIP_BLANKS_AND_EOL;
         }
         while ((ctxt->cur < ctxt->end) && (CUR != ']')) {
@@ -485,7 +485,7 @@ virConfParseValue(virConfParserCtxtPtr ctxt)
                 virConfError(ctxt, VIR_ERR_CONF_SYNTAX,
                              _("expecting a separator in list"));
                 virConfFreeList(lst);
-                return(NULL);
+                return NULL;
             }
             NEXT;
             SKIP_BLANKS_AND_EOL;
@@ -495,7 +495,7 @@ virConfParseValue(virConfParserCtxtPtr ctxt)
             tmp = virConfParseValue(ctxt);
             if (tmp == NULL) {
                 virConfFreeList(lst);
-                return(NULL);
+                return NULL;
             }
             prev = lst;
             while (prev->next != NULL) prev = prev->next;
@@ -508,33 +508,33 @@ virConfParseValue(virConfParserCtxtPtr ctxt)
             virConfError(ctxt, VIR_ERR_CONF_SYNTAX,
                          _("list is not closed with ]"));
             virConfFreeList(lst);
-            return(NULL);
+            return NULL;
         }
     } else if (c_isdigit(CUR) || (CUR == '-') || (CUR == '+')) {
         if (ctxt->conf->flags & VIR_CONF_FLAG_VMX_FORMAT) {
             virConfError(ctxt, VIR_ERR_CONF_SYNTAX,
                          _("numbers not allowed in VMX format"));
-            return(NULL);
+            return NULL;
         }
         if (virConfParseLong(ctxt, &l) < 0) {
-            return(NULL);
+            return NULL;
         }
         type = VIR_CONF_LONG;
     } else {
         virConfError(ctxt, VIR_ERR_CONF_SYNTAX, _("expecting a value"));
-        return(NULL);
+        return NULL;
     }
     if (VIR_ALLOC(ret) < 0) {
         virReportOOMError();
         virConfFreeList(lst);
         VIR_FREE(str);
-        return(NULL);
+        return NULL;
     }
     ret->type = type;
     ret->l = l;
     ret->str = str;
     ret->list = lst;
-    return(ret);
+    return ret;
 }

 /**
@@ -557,7 +557,7 @@ virConfParseName(virConfParserCtxtPtr ctxt)
     if (!c_isalpha(CUR) &&
         !((ctxt->conf->flags & VIR_CONF_FLAG_VMX_FORMAT) && (CUR == '.'))) {
         virConfError(ctxt, VIR_ERR_CONF_SYNTAX, _("expecting a name"));
-        return(NULL);
+        return NULL;
     }
     while ((ctxt->cur < ctxt->end) &&
            (c_isalnum(CUR) || (CUR == '_') ||
@@ -567,9 +567,9 @@ virConfParseName(virConfParserCtxtPtr ctxt)
     ret = strndup(base, ctxt->cur - base);
     if (ret == NULL) {
         virReportOOMError();
-        return(NULL);
+        return NULL;
     }
-    return(ret);
+    return ret;
 }

 /**
@@ -587,17 +587,17 @@ virConfParseComment(virConfParserCtxtPtr ctxt)
     char *comm;

     if (CUR != '#')
-        return(-1);
+        return -1;
     NEXT;
     base = ctxt->cur;
     while ((ctxt->cur < ctxt->end) && (!IS_EOL(CUR))) NEXT;
     comm = strndup(base, ctxt->cur - base);
     if (comm == NULL) {
         virReportOOMError();
-        return(-1);
+        return -1;
     }
     virConfAddEntry(ctxt->conf, NULL, NULL, comm);
-    return(0);
+    return 0;
 }

 /**
@@ -613,7 +613,7 @@ virConfParseSeparator(virConfParserCtxtPtr ctxt)
 {
     SKIP_BLANKS;
     if (ctxt->cur >= ctxt->end)
-        return(0);
+        return 0;
     if (IS_EOL(CUR)) {
         SKIP_BLANKS_AND_EOL;
     } else if (CUR == ';') {
@@ -621,9 +621,9 @@ virConfParseSeparator(virConfParserCtxtPtr ctxt)
         SKIP_BLANKS_AND_EOL;
     } else {
         virConfError(ctxt, VIR_ERR_CONF_SYNTAX, _("expecting a separator"));
-        return(-1);
+        return -1;
     }
-    return(0);
+    return 0;
 }

 /**
@@ -709,7 +709,7 @@ virConfParse(const char *filename, const char *content, int len,

     ctxt.conf = virConfCreate(filename, flags);
     if (ctxt.conf == NULL)
-        return(NULL);
+        return NULL;

     while (ctxt.cur < ctxt.end) {
         if (virConfParseStatement(&ctxt) < 0)
@@ -718,11 +718,11 @@ virConfParse(const char *filename, const char *content, int len,
             goto error;
     }

-    return(ctxt.conf);
+    return ctxt.conf;

 error:
     virConfFree(ctxt.conf);
-    return(NULL);
+    return NULL;
 }

 /************************************************************************
@@ -753,7 +753,7 @@ virConfReadFile(const char *filename, unsigned int flags)

     if (filename == NULL) {
         virConfError(NULL, VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(NULL);
+        return NULL;
     }

     if ((len = virFileReadAll(filename, MAX_CONFIG_FILE_SIZE, &content)) < 0) {
@@ -784,12 +784,12 @@ virConfReadMem(const char *memory, int len, unsigned int flags)
 {
     if ((memory == NULL) || (len < 0)) {
         virConfError(NULL, VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(NULL);
+        return NULL;
     }
     if (len == 0)
         len = strlen(memory);

-    return(virConfParse("memory conf", memory, len, flags));
+    return virConfParse("memory conf", memory, len, flags);
 }

 /**
@@ -818,7 +818,7 @@ virConfFree(virConfPtr conf)
         tmp = next;
     }
     VIR_FREE(conf);
-    return(0);
+    return 0;
 }

 /**
@@ -845,10 +845,10 @@ virConfGetValue(virConfPtr conf, const char *setting)
             ((conf->flags & VIR_CONF_FLAG_VMX_FORMAT &&
               STRCASEEQ(cur->name, setting)) ||
              STREQ(cur->name, setting)))
-            return(cur->value);
+            return cur->value;
         cur = cur->next;
     }
-    return(NULL);
+    return NULL;
 }

 /**
@@ -887,14 +887,14 @@ virConfSetValue (virConfPtr conf,
         if (VIR_ALLOC(cur) < 0) {
             virReportOOMError();
             virConfFreeValue(value);
-            return (-1);
+            return -1;
         }
         cur->comment = NULL;
         if (!(cur->name = strdup(setting))) {
             virReportOOMError();
             virConfFreeValue(value);
             VIR_FREE(cur);
-            return (-1);
+            return -1;
         }
         cur->value = value;
         if (prev) {
@@ -908,7 +908,7 @@ virConfSetValue (virConfPtr conf,
         virConfFreeValue(cur->value);
         cur->value = value;
     }
-    return (0);
+    return 0;
 }


@@ -932,7 +932,7 @@ virConfWriteFile(const char *filename, virConfPtr conf)
     unsigned int use;

     if (conf == NULL)
-        return(-1);
+        return -1;

     cur = conf->entries;
     while (cur != NULL) {
@@ -988,7 +988,7 @@ virConfWriteMem(char *memory, int *len, virConfPtr conf)
     unsigned int use;

     if ((memory == NULL) || (len == NULL) || (*len <= 0) || (conf == NULL))
-        return(-1);
+        return -1;

     cur = conf->entries;
     while (cur != NULL) {
diff --git a/src/util/hooks.c b/src/util/hooks.c
index b0c15fd..ce60b43 100644
--- a/src/util/hooks.c
+++ b/src/util/hooks.c
@@ -142,14 +142,14 @@ virHookInitialize(void) {
     for (i = 0;i < VIR_HOOK_DRIVER_LAST;i++) {
         res = virHookCheck(i, virHookDriverTypeToString(i));
         if (res < 0)
-            return(-1);
+            return -1;

         if (res == 1) {
             virHooksFound |= (1 << i);
             ret++;
         }
     }
-    return(ret);
+    return ret;
 }

 /**
@@ -165,13 +165,13 @@ int
 virHookPresent(int driver) {
     if ((driver < VIR_HOOK_DRIVER_DAEMON) ||
         (driver >= VIR_HOOK_DRIVER_LAST))
-        return(0);
+        return 0;
     if (virHooksFound == -1)
-        return(0);
+        return 0;

     if ((virHooksFound & (1 << driver)) == 0)
-        return(0);
-    return(1);
+        return 0;
+    return 1;
 }

 /**
@@ -215,7 +215,7 @@ virHookCall(int driver,

     if ((driver < VIR_HOOK_DRIVER_DAEMON) ||
         (driver >= VIR_HOOK_DRIVER_LAST))
-        return(1);
+        return 1;

     /*
      * We cache the availability of the script to minimize impact at
@@ -228,7 +228,7 @@ virHookCall(int driver,
         virHookInitialize();

     if ((virHooksFound & (1 << driver)) == 0)
-        return(1);
+        return 1;

     drvstr = virHookDriverTypeToString(driver);

@@ -248,7 +248,7 @@ virHookCall(int driver,
         virHookReportError(VIR_ERR_INTERNAL_ERROR,
                            _("Hook for %s, failed to find operation #%d"),
                            drvstr, op);
-        return(1);
+        return 1;
     }
     subopstr = virHookSubopTypeToString(sub_op);
     if (subopstr == NULL)
@@ -261,7 +261,7 @@ virHookCall(int driver,
         virHookReportError(VIR_ERR_INTERNAL_ERROR,
                            _("Failed to build path for %s hook"),
                            drvstr);
-        return(-1);
+        return -1;
     }

     cmd = virCommandNewArgList(path, id, opstr, subopstr, extra, NULL);
diff --git a/src/util/sexpr.c b/src/util/sexpr.c
index 3523d76..9e7df1d 100644
--- a/src/util/sexpr.c
+++ b/src/util/sexpr.c
@@ -42,7 +42,7 @@ sexpr_new(void)

     if (VIR_ALLOC(ret) < 0) {
         virReportOOMError();
-        return (NULL);
+        return NULL;
     }
     ret->kind = SEXPR_NIL;
     return ret;
@@ -187,12 +187,12 @@ struct sexpr *
 sexpr_append(struct sexpr *lst, const struct sexpr *value)
 {
     if (lst == NULL)
-        return (NULL);
+        return NULL;
     if (value == NULL)
-        return (lst);
+        return lst;
     if (append(lst, value) < 0)
-        return (NULL);
-    return (lst);
+        return NULL;
+    return lst;
 }

 /**
@@ -256,7 +256,7 @@ trim(const char *string)
 {
     while (IS_SPACE(*string))
         string++;
-    return (string);
+    return string;
 }

 /**
@@ -351,7 +351,7 @@ _string2sexpr(const char *buffer, size_t * end)

   error:
     sexpr_free(ret);
-    return (NULL);
+    return NULL;
 }

 /**
diff --git a/src/util/util.c b/src/util/util.c
index 15e6cfa..d91ab4f 100644
--- a/src/util/util.c
+++ b/src/util/util.c
@@ -605,7 +605,7 @@ int virFileIsLink(const char *linkpath)
     if (lstat(linkpath, &st) < 0)
         return -errno;

-    return (S_ISLNK(st.st_mode) != 0);
+    return S_ISLNK(st.st_mode) != 0;
 }


@@ -1813,19 +1813,19 @@ virParseNumber(const char **str)
     const char *cur = *str;

     if ((*cur < '0') || (*cur > '9'))
-        return (-1);
+        return -1;

     while (c_isdigit(*cur)) {
         unsigned int c = *cur - '0';

         if ((ret > INT_MAX / 10) ||
             ((ret == INT_MAX / 10) && (c > INT_MAX % 10)))
-            return (-1);
+            return -1;
         ret = ret * 10 + c;
         cur++;
     }
     *str = cur;
-    return (ret);
+    return ret;
 }


diff --git a/src/util/uuid.c b/src/util/uuid.c
index 23822ec..a84fd94 100644
--- a/src/util/uuid.c
+++ b/src/util/uuid.c
@@ -102,7 +102,7 @@ virUUIDGenerate(unsigned char *uuid)
     int err;

     if (uuid == NULL)
-        return(-1);
+        return -1;

     if ((err = virUUIDGenerateRandomBytes(uuid, VIR_UUID_BUFLEN))) {
         char ebuf[1024];
@@ -112,7 +112,7 @@ virUUIDGenerate(unsigned char *uuid)
         err = virUUIDGeneratePseudoRandomBytes(uuid, VIR_UUID_BUFLEN);
     }

-    return(err);
+    return err;
 }

 /**
@@ -222,7 +222,7 @@ virUUIDIsValid(unsigned char *uuid)
         if (uuid[i] == c)
             ctr++;

-    return (ctr != VIR_UUID_BUFLEN);
+    return ctr != VIR_UUID_BUFLEN;
 }

 static int
diff --git a/src/util/virhash.c b/src/util/virhash.c
index 6dec684..50c6ac5 100644
--- a/src/util/virhash.c
+++ b/src/util/virhash.c
@@ -98,7 +98,7 @@ static size_t
 virHashComputeKey(virHashTablePtr table, const void *name)
 {
     uint32_t value = table->keyCode(name, table->seed);
-    return (value % table->size);
+    return value % table->size;
 }

 /**
@@ -189,21 +189,21 @@ virHashGrow(virHashTablePtr table, size_t size)
 #endif

     if (table == NULL)
-        return (-1);
+        return -1;
     if (size < 8)
-        return (-1);
+        return -1;
     if (size > 8 * 2048)
-        return (-1);
+        return -1;

     oldsize = table->size;
     oldtable = table->table;
     if (oldtable == NULL)
-        return (-1);
+        return -1;

     if (VIR_ALLOC_N(table->table, size) < 0) {
         virReportOOMError();
         table->table = oldtable;
-        return (-1);
+        return -1;
     }
     table->size = size;

@@ -230,7 +230,7 @@ virHashGrow(virHashTablePtr table, size_t size)
               size, nbElem);
 #endif

-    return (0);
+    return 0;
 }

 /**
@@ -276,7 +276,7 @@ virHashAddOrUpdateEntry(virHashTablePtr table, const void *name,
     char *new_name;

     if ((table == NULL) || (name == NULL))
-        return (-1);
+        return -1;

     if (table->iterating)
         virHashIterationError(-1);
@@ -416,8 +416,8 @@ ssize_t
 virHashSize(virHashTablePtr table)
 {
     if (table == NULL)
-        return (-1);
-    return (table->nbElems);
+        return -1;
+    return table->nbElems;
 }

 /**
@@ -456,7 +456,7 @@ virHashRemoveEntry(virHashTablePtr table, const void *name)
     virHashEntryPtr *nextptr;

     if (table == NULL || name == NULL)
-        return (-1);
+        return -1;

     nextptr = table->table + virHashComputeKey(table, name);
     for (entry = *nextptr; entry; entry = entry->next) {
@@ -498,7 +498,7 @@ virHashForEach(virHashTablePtr table, virHashIterator iter, void *data)
     size_t i, count = 0;

     if (table == NULL || iter == NULL)
-        return (-1);
+        return -1;

     if (table->iterating)
         virHashIterationError(-1);
@@ -520,7 +520,7 @@ virHashForEach(virHashTablePtr table, virHashIterator iter, void *data)
     }
     table->iterating = false;

-    return (count);
+    return count;
 }

 /**
@@ -544,7 +544,7 @@ virHashRemoveSet(virHashTablePtr table,
     size_t i, count = 0;

     if (table == NULL || iter == NULL)
-        return (-1);
+        return -1;

     if (table->iterating)
         virHashIterationError(-1);
@@ -593,7 +593,7 @@ void *virHashSearch(virHashTablePtr table,
     size_t i;

     if (table == NULL || iter == NULL)
-        return (NULL);
+        return NULL;

     if (table->iterating)
         virHashIterationError(NULL);
diff --git a/src/util/virmacaddr.c b/src/util/virmacaddr.c
index 7b40397..beb6274 100644
--- a/src/util/virmacaddr.c
+++ b/src/util/virmacaddr.c
@@ -58,7 +58,7 @@ virMacAddrCompare(const char *p, const char *q)
     /* On machines where 'char' and 'int' are types of the same size, the
        difference of two 'unsigned char' values - including the sign bit -
        doesn't fit in an 'int'.  */
-    return (c > d ? 1 : c < d ? -1 : 0);
+    return c > d ? 1 : c < d ? -1 : 0;
 }

 /**
diff --git a/src/util/virnetlink.c b/src/util/virnetlink.c
index feb0fc7..f099974 100644
--- a/src/util/virnetlink.c
+++ b/src/util/virnetlink.c
@@ -312,7 +312,7 @@ virNetlinkEventServiceStop(void)
 bool
 virNetlinkEventServiceIsRunning(void)
 {
-    return (server != NULL);
+    return server != NULL;
 }

 /**
diff --git a/src/util/virsocketaddr.c b/src/util/virsocketaddr.c
index 5708e3d..b3104e7 100644
--- a/src/util/virsocketaddr.c
+++ b/src/util/virsocketaddr.c
@@ -48,7 +48,7 @@ static int virSocketAddrGetIPv4Addr(virSocketAddrPtr addr, virSocketAddrIPv4Ptr
     int i;

     if ((addr == NULL) || (tab == NULL) || (addr->data.stor.ss_family != AF_INET))
-        return(-1);
+        return -1;

     val = ntohl(addr->data.inet4.sin_addr.s_addr);

@@ -57,21 +57,21 @@ static int virSocketAddrGetIPv4Addr(virSocketAddrPtr addr, virSocketAddrIPv4Ptr
         val >>= 8;
     }

-    return(0);
+    return 0;
 }

 static int virSocketAddrGetIPv6Addr(virSocketAddrPtr addr, virSocketAddrIPv6Ptr tab) {
     int i;

     if ((addr == NULL) || (tab == NULL) || (addr->data.stor.ss_family != AF_INET6))
-        return(-1);
+        return -1;

     for (i = 0;i < 8;i++) {
         (*tab)[i] = ((addr->data.inet6.sin6_addr.s6_addr[2 * i] << 8) |
                      addr->data.inet6.sin6_addr.s6_addr[2 * i + 1]);
     }

-    return(0);
+    return 0;
 }

 /**
@@ -120,7 +120,7 @@ int virSocketAddrParse(virSocketAddrPtr addr, const char *val, int family) {
     }

     freeaddrinfo(res);
-    return(len);
+    return len;
 }

 /*
@@ -444,13 +444,13 @@ int virSocketAddrCheckNetmask(virSocketAddrPtr addr1, virSocketAddrPtr addr2,
     int i;

     if ((addr1 == NULL) || (addr2 == NULL) || (netmask == NULL))
-        return(-1);
+        return -1;
     if ((addr1->data.stor.ss_family != addr2->data.stor.ss_family) ||
         (addr1->data.stor.ss_family != netmask->data.stor.ss_family))
-        return(-1);
+        return -1;

     if (virSocketAddrIsNetmask(netmask) != 0)
-        return(-1);
+        return -1;

     if (addr1->data.stor.ss_family == AF_INET) {
         virSocketAddrIPv4 t1, t2, tm;
@@ -458,11 +458,11 @@ int virSocketAddrCheckNetmask(virSocketAddrPtr addr1, virSocketAddrPtr addr2,
         if ((virSocketAddrGetIPv4Addr(addr1, &t1) < 0) ||
             (virSocketAddrGetIPv4Addr(addr2, &t2) < 0) ||
             (virSocketAddrGetIPv4Addr(netmask, &tm) < 0))
-            return(-1);
+            return -1;

         for (i = 0;i < 4;i++) {
             if ((t1[i] & tm[i]) != (t2[i] & tm[i]))
-                return(0);
+                return 0;
         }

     } else if (addr1->data.stor.ss_family == AF_INET6) {
@@ -471,17 +471,17 @@ int virSocketAddrCheckNetmask(virSocketAddrPtr addr1, virSocketAddrPtr addr2,
         if ((virSocketAddrGetIPv6Addr(addr1, &t1) < 0) ||
             (virSocketAddrGetIPv6Addr(addr2, &t2) < 0) ||
             (virSocketAddrGetIPv6Addr(netmask, &tm) < 0))
-            return(-1);
+            return -1;

         for (i = 0;i < 8;i++) {
             if ((t1[i] & tm[i]) != (t2[i] & tm[i]))
-                return(0);
+                return 0;
         }

     } else {
-        return(-1);
+        return -1;
     }
-    return(1);
+    return 1;
 }

 /**
@@ -500,44 +500,44 @@ int virSocketAddrGetRange(virSocketAddrPtr start, virSocketAddrPtr end) {
     int ret = 0, i;

     if ((start == NULL) || (end == NULL))
-        return(-1);
+        return -1;
     if (start->data.stor.ss_family != end->data.stor.ss_family)
-        return(-1);
+        return -1;

     if (start->data.stor.ss_family == AF_INET) {
         virSocketAddrIPv4 t1, t2;

         if ((virSocketAddrGetIPv4Addr(start, &t1) < 0) ||
             (virSocketAddrGetIPv4Addr(end, &t2) < 0))
-            return(-1);
+            return -1;

         for (i = 0;i < 2;i++) {
             if (t1[i] != t2[i])
-                return(-1);
+                return -1;
         }
         ret = (t2[2] - t1[2]) * 256 + (t2[3] - t1[3]);
         if (ret < 0)
-            return(-1);
+            return -1;
         ret++;
     } else if (start->data.stor.ss_family == AF_INET6) {
         virSocketAddrIPv6 t1, t2;

         if ((virSocketAddrGetIPv6Addr(start, &t1) < 0) ||
             (virSocketAddrGetIPv6Addr(end, &t2) < 0))
-            return(-1);
+            return -1;

         for (i = 0;i < 7;i++) {
             if (t1[i] != t2[i])
-                return(-1);
+                return -1;
         }
         ret = t2[7] - t1[7];
         if (ret < 0)
-            return(-1);
+            return -1;
         ret++;
     } else {
-        return(-1);
+        return -1;
     }
-    return(ret);
+    return ret;
 }


diff --git a/src/util/virterror.c b/src/util/virterror.c
index b4e496a..bb127b6 100644
--- a/src/util/virterror.c
+++ b/src/util/virterror.c
@@ -31,13 +31,13 @@ virErrorLogPriorityFunc virErrorLogPriorityFilter = NULL;
 static virLogPriority virErrorLevelPriority(virErrorLevel level) {
     switch (level) {
         case VIR_ERR_NONE:
-            return(VIR_LOG_INFO);
+            return VIR_LOG_INFO;
         case VIR_ERR_WARNING:
-            return(VIR_LOG_WARN);
+            return VIR_LOG_WARN;
         case VIR_ERR_ERROR:
-            return(VIR_LOG_ERROR);
+            return VIR_LOG_ERROR;
     }
-    return(VIR_LOG_ERROR);
+    return VIR_LOG_ERROR;
 }

 static const char *virErrorDomainName(virErrorDomain domain) {
@@ -179,7 +179,7 @@ static const char *virErrorDomainName(virErrorDomain domain) {
             dom = "Capabilities ";
             break;
     }
-    return(dom);
+    return dom;
 }


@@ -763,7 +763,7 @@ virErrorMsg(virErrorNumber error, const char *info)

     switch (error) {
         case VIR_ERR_OK:
-            return (NULL);
+            return NULL;
         case VIR_ERR_INTERNAL_ERROR:
             if (info != NULL)
               errmsg = _("internal error %s");
@@ -1245,7 +1245,7 @@ virErrorMsg(virErrorNumber error, const char *info)
                 errmsg = _("numerical overflow: %s");
             break;
     }
-    return (errmsg);
+    return errmsg;
 }

 /**
diff --git a/src/util/xml.c b/src/util/xml.c
index b426653..1e0a48a 100644
--- a/src/util/xml.c
+++ b/src/util/xml.c
@@ -68,7 +68,7 @@ virXPathString(const char *xpath,
     if ((ctxt == NULL) || (xpath == NULL)) {
         virXMLError(VIR_ERR_INTERNAL_ERROR,
                     "%s", _("Invalid parameter to virXPathString()"));
-        return (NULL);
+        return NULL;
     }
     relnode = ctxt->node;
     obj = xmlXPathEval(BAD_CAST xpath, ctxt);
@@ -76,14 +76,14 @@ virXPathString(const char *xpath,
     if ((obj == NULL) || (obj->type != XPATH_STRING) ||
         (obj->stringval == NULL) || (obj->stringval[0] == 0)) {
         xmlXPathFreeObject(obj);
-        return (NULL);
+        return NULL;
     }
     ret = strdup((char *) obj->stringval);
     xmlXPathFreeObject(obj);
     if (ret == NULL) {
         virReportOOMError();
     }
-    return (ret);
+    return ret;
 }

 /**
@@ -138,7 +138,7 @@ virXPathNumber(const char *xpath,
     if ((ctxt == NULL) || (xpath == NULL) || (value == NULL)) {
         virXMLError(VIR_ERR_INTERNAL_ERROR,
                     "%s", _("Invalid parameter to virXPathNumber()"));
-        return (-1);
+        return -1;
     }
     relnode = ctxt->node;
     obj = xmlXPathEval(BAD_CAST xpath, ctxt);
@@ -146,12 +146,12 @@ virXPathNumber(const char *xpath,
     if ((obj == NULL) || (obj->type != XPATH_NUMBER) ||
         (isnan(obj->floatval))) {
         xmlXPathFreeObject(obj);
-        return (-1);
+        return -1;
     }

     *value = obj->floatval;
     xmlXPathFreeObject(obj);
-    return (0);
+    return 0;
 }

 static int
@@ -167,7 +167,7 @@ virXPathLongBase(const char *xpath,
     if ((ctxt == NULL) || (xpath == NULL) || (value == NULL)) {
         virXMLError(VIR_ERR_INTERNAL_ERROR,
                     "%s", _("Invalid parameter to virXPathLong()"));
-        return (-1);
+        return -1;
     }
     relnode = ctxt->node;
     obj = xmlXPathEval(BAD_CAST xpath, ctxt);
@@ -194,7 +194,7 @@ virXPathLongBase(const char *xpath,
     }

     xmlXPathFreeObject(obj);
-    return (ret);
+    return ret;
 }

 /**
@@ -280,7 +280,7 @@ virXPathULongBase(const char *xpath,
     if ((ctxt == NULL) || (xpath == NULL) || (value == NULL)) {
         virXMLError(VIR_ERR_INTERNAL_ERROR,
                     "%s", _("Invalid parameter to virXPathULong()"));
-        return (-1);
+        return -1;
     }
     relnode = ctxt->node;
     obj = xmlXPathEval(BAD_CAST xpath, ctxt);
@@ -307,7 +307,7 @@ virXPathULongBase(const char *xpath,
     }

     xmlXPathFreeObject(obj);
-    return (ret);
+    return ret;
 }

 /**
@@ -404,7 +404,7 @@ virXPathULongLong(const char *xpath,
     if ((ctxt == NULL) || (xpath == NULL) || (value == NULL)) {
         virXMLError(VIR_ERR_INTERNAL_ERROR,
                     "%s", _("Invalid parameter to virXPathULong()"));
-        return (-1);
+        return -1;
     }
     relnode = ctxt->node;
     obj = xmlXPathEval(BAD_CAST xpath, ctxt);
@@ -431,7 +431,7 @@ virXPathULongLong(const char *xpath,
     }

     xmlXPathFreeObject(obj);
-    return (ret);
+    return ret;
 }

 /**
@@ -458,7 +458,7 @@ virXPathLongLong(const char *xpath,
     if ((ctxt == NULL) || (xpath == NULL) || (value == NULL)) {
         virXMLError(VIR_ERR_INTERNAL_ERROR,
                     "%s", _("Invalid parameter to virXPathLongLong()"));
-        return (-1);
+        return -1;
     }
     relnode = ctxt->node;
     obj = xmlXPathEval(BAD_CAST xpath, ctxt);
@@ -485,7 +485,7 @@ virXPathLongLong(const char *xpath,
     }

     xmlXPathFreeObject(obj);
-    return (ret);
+    return ret;
 }

 char *
@@ -515,7 +515,7 @@ virXPathBoolean(const char *xpath,
     if ((ctxt == NULL) || (xpath == NULL)) {
         virXMLError(VIR_ERR_INTERNAL_ERROR,
                     "%s", _("Invalid parameter to virXPathBoolean()"));
-        return (-1);
+        return -1;
     }
     relnode = ctxt->node;
     obj = xmlXPathEval(BAD_CAST xpath, ctxt);
@@ -523,12 +523,12 @@ virXPathBoolean(const char *xpath,
     if ((obj == NULL) || (obj->type != XPATH_BOOLEAN) ||
         (obj->boolval < 0) || (obj->boolval > 1)) {
         xmlXPathFreeObject(obj);
-        return (-1);
+        return -1;
     }
     ret = obj->boolval;

     xmlXPathFreeObject(obj);
-    return (ret);
+    return ret;
 }

 /**
@@ -552,7 +552,7 @@ virXPathNode(const char *xpath,
     if ((ctxt == NULL) || (xpath == NULL)) {
         virXMLError(VIR_ERR_INTERNAL_ERROR,
                     "%s", _("Invalid parameter to virXPathNode()"));
-        return (NULL);
+        return NULL;
     }
     relnode = ctxt->node;
     obj = xmlXPathEval(BAD_CAST xpath, ctxt);
@@ -561,12 +561,12 @@ virXPathNode(const char *xpath,
         (obj->nodesetval == NULL) || (obj->nodesetval->nodeNr <= 0) ||
         (obj->nodesetval->nodeTab == NULL)) {
         xmlXPathFreeObject(obj);
-        return (NULL);
+        return NULL;
     }

     ret = obj->nodesetval->nodeTab[0];
     xmlXPathFreeObject(obj);
-    return (ret);
+    return ret;
 }

 /**
@@ -592,7 +592,7 @@ virXPathNodeSet(const char *xpath,
     if ((ctxt == NULL) || (xpath == NULL)) {
         virXMLError(VIR_ERR_INTERNAL_ERROR,
                     "%s", _("Invalid parameter to virXPathNodeSet()"));
-        return (-1);
+        return -1;
     }

     if (list != NULL)
@@ -602,18 +602,18 @@ virXPathNodeSet(const char *xpath,
     obj = xmlXPathEval(BAD_CAST xpath, ctxt);
     ctxt->node = relnode;
     if (obj == NULL)
-        return(0);
+        return 0;

     if (obj->type != XPATH_NODESET) {
         virXMLError(VIR_ERR_INTERNAL_ERROR,
                     _("Incorrect xpath '%s'"), xpath);
         xmlXPathFreeObject(obj);
-        return (-1);
+        return -1;
     }

     if ((obj->nodesetval == NULL)  || (obj->nodesetval->nodeNr < 0)) {
         xmlXPathFreeObject(obj);
-        return (0);
+        return 0;
     }

     ret = obj->nodesetval->nodeNr;
@@ -627,7 +627,7 @@ virXPathNodeSet(const char *xpath,
         }
     }
     xmlXPathFreeObject(obj);
-    return (ret);
+    return ret;
 }


diff --git a/src/xen/xen_driver.c b/src/xen/xen_driver.c
index 0238ed7..c5da1c4 100644
--- a/src/xen/xen_driver.c
+++ b/src/xen/xen_driver.c
@@ -135,17 +135,17 @@ xenDomainUsedCpus(virDomainPtr dom)
     xenUnifiedPrivatePtr priv;

     if (!VIR_IS_CONNECTED_DOMAIN(dom))
-        return (NULL);
+        return NULL;

     priv = dom->conn->privateData;

     if (priv->nbNodeCpus <= 0)
-        return(NULL);
+        return NULL;
     nb_vcpu = xenUnifiedDomainGetMaxVcpus(dom);
     if (nb_vcpu <= 0)
-        return(NULL);
+        return NULL;
     if (xenUnifiedNodeGetInfo(dom->conn, &nodeinfo) < 0)
-        return(NULL);
+        return NULL;

     if (VIR_ALLOC_N(cpulist, priv->nbNodeCpus) < 0) {
         virReportOOMError();
@@ -184,7 +184,7 @@ done:
     VIR_FREE(cpulist);
     VIR_FREE(cpumap);
     VIR_FREE(cpuinfo);
-    return(res);
+    return res;
 }

 #ifdef WITH_LIBVIRTD
@@ -1250,7 +1250,7 @@ xenUnifiedDomainGetXMLDesc(virDomainPtr dom, unsigned int flags)
             xenUnifiedUnlock(priv);
             res = xenDaemonDomainGetXMLDesc(dom, flags, cpus);
             VIR_FREE(cpus);
-            return(res);
+            return res;
         }
     }

@@ -1682,10 +1682,10 @@ xenUnifiedDomainGetSchedulerType (virDomainPtr dom, int *nparams)
         if (priv->opened[i] && drivers[i]->xenDomainGetSchedulerType) {
             schedulertype = drivers[i]->xenDomainGetSchedulerType (dom, nparams);
             if (schedulertype != NULL)
-                return(schedulertype);
+                return schedulertype;
         }
     }
-    return(NULL);
+    return NULL;
 }

 static int
@@ -1703,10 +1703,10 @@ xenUnifiedDomainGetSchedulerParametersFlags(virDomainPtr dom,
         if (priv->opened[i] && drivers[i]->xenDomainGetSchedulerParameters) {
            ret = drivers[i]->xenDomainGetSchedulerParameters(dom, params, nparams);
            if (ret == 0)
-               return(0);
+               return 0;
         }
     }
-    return(-1);
+    return -1;
 }

 static int
@@ -1738,7 +1738,7 @@ xenUnifiedDomainSetSchedulerParametersFlags(virDomainPtr dom,
         }
     }

-    return(-1);
+    return -1;
 }

 static int
@@ -1826,12 +1826,12 @@ xenUnifiedNodeGetFreeMemory (virConnectPtr conn)
         ret = xenHypervisorNodeGetCellsFreeMemory (conn, &freeMem,
                                                     -1, 1);
         if (ret != 1)
-            return (0);
-        return(freeMem);
+            return 0;
+        return freeMem;
     }

     xenUnifiedError(VIR_ERR_NO_SUPPORT, __FUNCTION__);
-    return(0);
+    return 0;
 }


@@ -1856,7 +1856,7 @@ xenUnifiedDomainEventRegister(virConnectPtr conn,
                                       callback, opaque, freefunc);

     xenUnifiedUnlock(priv);
-    return (ret);
+    return ret;
 }


@@ -1908,7 +1908,7 @@ xenUnifiedDomainEventRegisterAny(virConnectPtr conn,
         ret = -1;

     xenUnifiedUnlock(priv);
-    return (ret);
+    return ret;
 }

 static int
diff --git a/src/xen/xen_hypervisor.c b/src/xen/xen_hypervisor.c
index 4401b68..eb8b67e 100644
--- a/src/xen/xen_hypervisor.c
+++ b/src/xen/xen_hypervisor.c
@@ -526,9 +526,9 @@ static int
 lock_pages(void *addr, size_t len)
 {
 #ifdef __linux__
-        return (mlock(addr, len));
+        return mlock(addr, len);
 #elif defined(__sun)
-        return (0);
+        return 0;
 #endif
 }

@@ -536,9 +536,9 @@ static int
 unlock_pages(void *addr, size_t len)
 {
 #ifdef __linux__
-        return (munlock(addr, len));
+        return munlock(addr, len);
 #elif defined(__sun)
-        return (0);
+        return 0;
 #endif
 }

@@ -902,7 +902,7 @@ xenHypervisorDoV0Op(int handle, xen_op_v0 * op)

     if (lock_pages(op, sizeof(dom0_op_t)) < 0) {
         virXenError(VIR_ERR_XEN_CALL, " locking");
-        return (-1);
+        return -1;
     }

     ret = ioctl(handle, xen_ioctl_hypercall_cmd, (unsigned long) &hc);
@@ -917,9 +917,9 @@ xenHypervisorDoV0Op(int handle, xen_op_v0 * op)
     }

     if (ret < 0)
-        return (-1);
+        return -1;

-    return (0);
+    return 0;
 }
 /**
  * xenHypervisorDoV1Op:
@@ -944,7 +944,7 @@ xenHypervisorDoV1Op(int handle, xen_op_v1* op)

     if (lock_pages(op, sizeof(dom0_op_t)) < 0) {
         virXenError(VIR_ERR_XEN_CALL, " locking");
-        return (-1);
+        return -1;
     }

     ret = ioctl(handle, xen_ioctl_hypercall_cmd, (unsigned long) &hc);
@@ -959,9 +959,9 @@ xenHypervisorDoV1Op(int handle, xen_op_v1* op)
     }

     if (ret < 0)
-        return (-1);
+        return -1;

-    return (0);
+    return 0;
 }

 /**
@@ -987,7 +987,7 @@ xenHypervisorDoV2Sys(int handle, xen_op_v2_sys* op)

     if (lock_pages(op, sizeof(dom0_op_t)) < 0) {
         virXenError(VIR_ERR_XEN_CALL, " locking");
-        return (-1);
+        return -1;
     }

     ret = ioctl(handle, xen_ioctl_hypercall_cmd, (unsigned long) &hc);
@@ -1002,9 +1002,9 @@ xenHypervisorDoV2Sys(int handle, xen_op_v2_sys* op)
     }

     if (ret < 0)
-        return (-1);
+        return -1;

-    return (0);
+    return 0;
 }

 /**
@@ -1030,7 +1030,7 @@ xenHypervisorDoV2Dom(int handle, xen_op_v2_dom* op)

     if (lock_pages(op, sizeof(dom0_op_t)) < 0) {
         virXenError(VIR_ERR_XEN_CALL, " locking");
-        return (-1);
+        return -1;
     }

     ret = ioctl(handle, xen_ioctl_hypercall_cmd, (unsigned long) &hc);
@@ -1045,9 +1045,9 @@ xenHypervisorDoV2Dom(int handle, xen_op_v2_dom* op)
     }

     if (ret < 0)
-        return (-1);
+        return -1;

-    return (0);
+    return 0;
 }

 /**
@@ -1070,7 +1070,7 @@ virXen_getdomaininfolist(int handle, int first_domain, int maxids,
     if (lock_pages(XEN_GETDOMAININFOLIST_DATA(dominfos),
               XEN_GETDOMAININFO_SIZE * maxids) < 0) {
         virXenError(VIR_ERR_XEN_CALL, " locking");
-        return (-1);
+        return -1;
     }
     if (hv_versions.hypervisor > 1) {
         xen_op_v2_sys op;
@@ -1127,7 +1127,7 @@ virXen_getdomaininfolist(int handle, int first_domain, int maxids,
         virXenError(VIR_ERR_XEN_CALL, " release");
         ret = -1;
     }
-    return(ret);
+    return ret;
 }

 static int
@@ -1197,7 +1197,7 @@ xenHypervisorGetSchedulerType(virDomainPtr domain, int *nparams)
         op.cmd = XEN_V2_OP_GETSCHEDULERID;
         ret = xenHypervisorDoV2Sys(priv->handle, &op);
         if (ret < 0)
-            return(NULL);
+            return NULL;

         switch (op.u.getschedulerid.sched_id){
             case XEN_SCHEDULER_SEDF:
@@ -1291,7 +1291,7 @@ xenHypervisorGetSchedulerParameters(virDomainPtr domain,

                 /* TODO: Implement for Xen/SEDF */
                 TODO
-                return(-1);
+                return -1;
             case XEN_SCHEDULER_CREDIT:
                 memset(&op_dom, 0, sizeof(op_dom));
                 op_dom.cmd = XEN_V2_OP_SCHEDULER;
@@ -1300,7 +1300,7 @@ xenHypervisorGetSchedulerParameters(virDomainPtr domain,
                 op_dom.u.getschedinfo.cmd = XEN_DOMCTL_SCHEDOP_getinfo;
                 ret = xenHypervisorDoV2Dom(priv->handle, &op_dom);
                 if (ret < 0)
-                    return(-1);
+                    return -1;

                 if (virTypedParameterAssign(&params[0],
                                             VIR_DOMAIN_SCHEDULER_WEIGHT,
@@ -1403,7 +1403,7 @@ xenHypervisorSetSchedulerParameters(virDomainPtr domain,
         case XEN_SCHEDULER_SEDF:
             /* TODO: Implement for Xen/SEDF */
             TODO
-            return(-1);
+            return -1;
         case XEN_SCHEDULER_CREDIT: {
             memset(&op_dom, 0, sizeof(op_dom));
             op_dom.cmd = XEN_V2_OP_SCHEDULER;
@@ -1426,7 +1426,7 @@ xenHypervisorSetSchedulerParameters(virDomainPtr domain,
                         virXenError(VIR_ERR_INVALID_ARG,
                                     _("Credit scheduler weight parameter (%d) "
                                       "is out of range (1-65535)"), val);
-                        return(-1);
+                        return -1;
                     }
                     op_dom.u.getschedinfo.u.credit.weight = val;
                 } else if (STREQ(params[i].field, VIR_DOMAIN_SCHEDULER_CAP)) {
@@ -1435,7 +1435,7 @@ xenHypervisorSetSchedulerParameters(virDomainPtr domain,
                         virXenError(VIR_ERR_INVALID_ARG,
                                     _("Credit scheduler cap parameter (%d) is "
                                       "out of range (0-65534)"), val);
-                        return(-1);
+                        return -1;
                     }
                     op_dom.u.getschedinfo.u.credit.cap = val;
                 }
@@ -1553,7 +1553,7 @@ virXen_pausedomain(int handle, int id)
         op.u.domain.domain = (domid_t) id;
         ret = xenHypervisorDoV0Op(handle, &op);
     }
-    return(ret);
+    return ret;
 }

 /**
@@ -1592,7 +1592,7 @@ virXen_unpausedomain(int handle, int id)
         op.u.domain.domain = (domid_t) id;
         ret = xenHypervisorDoV0Op(handle, &op);
     }
-    return(ret);
+    return ret;
 }

 /**
@@ -1631,7 +1631,7 @@ virXen_destroydomain(int handle, int id)
         op.u.domain.domain = (domid_t) id;
         ret = xenHypervisorDoV0Op(handle, &op);
     }
-    return(ret);
+    return ret;
 }

 /**
@@ -1677,7 +1677,7 @@ virXen_setmaxmem(int handle, int id, unsigned long memory)
         op.u.setmaxmem.maxmem = memory;
         ret = xenHypervisorDoV0Op(handle, &op);
     }
-    return(ret);
+    return ret;
 }

 /**
@@ -1720,7 +1720,7 @@ virXen_setmaxvcpus(int handle, int id, unsigned int vcpus)
         op.u.setmaxvcpu.maxvcpu = vcpus;
         ret = xenHypervisorDoV0Op(handle, &op);
     }
-    return(ret);
+    return ret;
 }

 /**
@@ -1749,7 +1749,7 @@ virXen_setvcpumap(int handle, int id, unsigned int vcpu,

         if (lock_pages(cpumap, maplen) < 0) {
             virXenError(VIR_ERR_XEN_CALL, " locking");
-            return (-1);
+            return -1;
         }
         memset(&op, 0, sizeof(op));
         op.cmd = XEN_V2_OP_SETVCPUMAP;
@@ -1760,7 +1760,7 @@ virXen_setvcpumap(int handle, int id, unsigned int vcpu,
         if (maplen < 8) {
             if (VIR_ALLOC_N(new, sizeof(uint64_t)) < 0) {
                 virReportOOMError();
-                return (-1);
+                return -1;
             }
             memcpy(new, cpumap, maplen);
             bitmap = new;
@@ -1792,7 +1792,7 @@ virXen_setvcpumap(int handle, int id, unsigned int vcpu,
         int j;

         if ((maplen > (int)sizeof(cpumap_t)) || (sizeof(cpumap_t) & 7))
-            return (-1);
+            return -1;

         memset(pm, 0, sizeof(cpumap_t));
         for (j = 0; j < maplen; j++)
@@ -1818,7 +1818,7 @@ virXen_setvcpumap(int handle, int id, unsigned int vcpu,
             ret = xenHypervisorDoV0Op(handle, &op);
         }
     }
-    return(ret);
+    return ret;
 }


@@ -1853,7 +1853,7 @@ virXen_getvcpusinfo(int handle, int id, unsigned int vcpu, virVcpuInfoPtr ipt,
         ret = xenHypervisorDoV2Dom(handle, &op);

         if (ret < 0)
-            return(-1);
+            return -1;
         ipt->number = vcpu;
         if (hv_versions.dom_interface < 5) {
             if (op.u.getvcpuinfo.online) {
@@ -1881,7 +1881,7 @@ virXen_getvcpusinfo(int handle, int id, unsigned int vcpu, virVcpuInfoPtr ipt,
         if ((cpumap != NULL) && (maplen > 0)) {
             if (lock_pages(cpumap, maplen) < 0) {
                 virXenError(VIR_ERR_XEN_CALL, " locking");
-                return (-1);
+                return -1;
             }
             memset(cpumap, 0, maplen);
             memset(&op, 0, sizeof(op));
@@ -1918,7 +1918,7 @@ virXen_getvcpusinfo(int handle, int id, unsigned int vcpu, virVcpuInfoPtr ipt,
             op.u.getvcpuinfo.vcpu = vcpu;
             ret = xenHypervisorDoV1Op(handle, &op);
             if (ret < 0)
-                return(-1);
+                return -1;
             ipt->number = vcpu;
             if (op.u.getvcpuinfo.online) {
                 if (op.u.getvcpuinfo.running) ipt->state = VIR_VCPU_RUNNING;
@@ -1942,7 +1942,7 @@ virXen_getvcpusinfo(int handle, int id, unsigned int vcpu, virVcpuInfoPtr ipt,
             op.u.getvcpuinfo.vcpu = vcpu;
             ret = xenHypervisorDoV0Op(handle, &op);
             if (ret < 0)
-                return(-1);
+                return -1;
             ipt->number = vcpu;
             if (op.u.getvcpuinfo.online) {
                 if (op.u.getvcpuinfo.running) ipt->state = VIR_VCPU_RUNNING;
@@ -1959,7 +1959,7 @@ virXen_getvcpusinfo(int handle, int id, unsigned int vcpu, virVcpuInfoPtr ipt,
             }
         }
     }
-    return(ret);
+    return ret;
 }

 /**
@@ -1983,8 +1983,8 @@ xenHypervisorInit(struct xenHypervisorVersions *override_versions)

     if (initialized) {
         if (hv_versions.hypervisor == -1)
-            return (-1);
-        return(0);
+            return -1;
+        return 0;
     }
     initialized = 1;
     in_init = 1;
@@ -2034,7 +2034,7 @@ xenHypervisorInit(struct xenHypervisorVersions *override_versions)
     ret = open(XEN_HYPERVISOR_SOCKET, O_RDWR);
     if (ret < 0) {
         hv_versions.hypervisor = -1;
-        return(-1);
+        return -1;
     }
     fd = ret;

@@ -2083,7 +2083,7 @@ xenHypervisorInit(struct xenHypervisorVersions *override_versions)
                 (unsigned long) IOCTL_PRIVCMD_HYPERCALL);
     VIR_FORCE_CLOSE(fd);
     in_init = 0;
-    return(-1);
+    return -1;

  detect_v2:
     /*
@@ -2095,7 +2095,7 @@ xenHypervisorInit(struct xenHypervisorVersions *override_versions)

     if (VIR_ALLOC(ipt) < 0) {
         virReportOOMError();
-        return(-1);
+        return -1;
     }
     /* Currently consider RHEL5.0 Fedora7, xen-3.1, and xen-unstable */
     hv_versions.sys_interface = 2; /* XEN_SYSCTL_INTERFACE_VERSION */
@@ -2189,13 +2189,13 @@ xenHypervisorInit(struct xenHypervisorVersions *override_versions)
     VIR_FORCE_CLOSE(fd);
     in_init = 0;
     VIR_FREE(ipt);
-    return(-1);
+    return -1;

  done:
     VIR_FORCE_CLOSE(fd);
     in_init = 0;
     VIR_FREE(ipt);
-    return(0);
+    return 0;
 }

 /**
@@ -2227,12 +2227,12 @@ xenHypervisorOpen(virConnectPtr conn,
     ret = open(XEN_HYPERVISOR_SOCKET, O_RDWR);
     if (ret < 0) {
         virXenError(VIR_ERR_NO_XEN, "%s", XEN_HYPERVISOR_SOCKET);
-        return (-1);
+        return -1;
     }

     priv->handle = ret;

-    return(0);
+    return 0;
 }

 /**
@@ -2250,7 +2250,7 @@ xenHypervisorClose(virConnectPtr conn)
     xenUnifiedPrivatePtr priv;

     if (conn == NULL)
-        return (-1);
+        return -1;

     priv = (xenUnifiedPrivatePtr) conn->privateData;

@@ -2259,9 +2259,9 @@ xenHypervisorClose(virConnectPtr conn)

     ret = VIR_CLOSE(priv->handle);
     if (ret < 0)
-        return (-1);
+        return -1;

-    return (0);
+    return 0;
 }


@@ -2283,9 +2283,9 @@ xenHypervisorGetVersion(virConnectPtr conn, unsigned long *hvVer)
         return -1;
     priv = (xenUnifiedPrivatePtr) conn->privateData;
     if (priv->handle < 0 || hvVer == NULL)
-        return (-1);
+        return -1;
     *hvVer = (hv_versions.hv >> 16) * 1000000 + (hv_versions.hv & 0xFFFF) * 1000;
-    return(0);
+    return 0;
 }

 struct guest_arch {
@@ -2821,12 +2821,12 @@ xenHypervisorNumOfDomains(virConnectPtr conn)
         return -1;
     priv = (xenUnifiedPrivatePtr) conn->privateData;
     if (priv->handle < 0)
-        return (-1);
+        return -1;

  retry:
     if (!(XEN_GETDOMAININFOLIST_ALLOC(dominfos, maxids))) {
         virReportOOMError();
-        return(-1);
+        return -1;
     }

     XEN_GETDOMAININFOLIST_CLEAR(dominfos, maxids);
@@ -2836,7 +2836,7 @@ xenHypervisorNumOfDomains(virConnectPtr conn)
     XEN_GETDOMAININFOLIST_FREE(dominfos);

     if (ret < 0)
-        return (-1);
+        return -1;

     nbids = ret;
     /* Can't possibly have more than 65,000 concurrent guests
@@ -2853,8 +2853,8 @@ xenHypervisorNumOfDomains(virConnectPtr conn)
         nbids = -1;
     }
     if ((nbids < 0) || (nbids > maxids))
-        return(-1);
-    return(nbids);
+        return -1;
+    return nbids;
 }

 /**
@@ -2880,14 +2880,14 @@ xenHypervisorListDomains(virConnectPtr conn, int *ids, int maxids)
     priv = (xenUnifiedPrivatePtr) conn->privateData;
     if (priv->handle < 0 ||
         (ids == NULL) || (maxids < 0))
-        return (-1);
+        return -1;

     if (maxids == 0)
-        return(0);
+        return 0;

     if (!(XEN_GETDOMAININFOLIST_ALLOC(dominfos, maxids))) {
         virReportOOMError();
-        return(-1);
+        return -1;
     }

     XEN_GETDOMAININFOLIST_CLEAR(dominfos, maxids);
@@ -2897,13 +2897,13 @@ xenHypervisorListDomains(virConnectPtr conn, int *ids, int maxids)

     if (ret < 0) {
         XEN_GETDOMAININFOLIST_FREE(dominfos);
-        return (-1);
+        return -1;
     }

     nbids = ret;
     if ((nbids < 0) || (nbids > maxids)) {
         XEN_GETDOMAININFOLIST_FREE(dominfos);
-        return(-1);
+        return -1;
     }

     for (i = 0;i < nbids;i++) {
@@ -2911,7 +2911,7 @@ xenHypervisorListDomains(virConnectPtr conn, int *ids, int maxids)
     }

     XEN_GETDOMAININFOLIST_FREE(dominfos);
-    return (nbids);
+    return nbids;
 }


@@ -2926,7 +2926,7 @@ xenHypervisorDomainGetOSType (virDomainPtr dom)
     if (priv->handle < 0) {
         virXenError(VIR_ERR_INTERNAL_ERROR, "%s",
                     _("domain shut off or invalid"));
-        return (NULL);
+        return NULL;
     }

     /* HV's earlier than 3.1.0 don't include the HVM flags in guests status*/
@@ -2934,7 +2934,7 @@ xenHypervisorDomainGetOSType (virDomainPtr dom)
         hv_versions.dom_interface < 4) {
         virXenError(VIR_ERR_INTERNAL_ERROR, "%s",
                     _("unsupported in dom interface < 4"));
-        return (NULL);
+        return NULL;
     }

     XEN_GETDOMAININFO_CLEAR(dominfo);
@@ -2942,13 +2942,13 @@ xenHypervisorDomainGetOSType (virDomainPtr dom)
     if (virXen_getdomaininfo(priv->handle, dom->id, &dominfo) < 0) {
         virXenError(VIR_ERR_INTERNAL_ERROR, "%s",
                     _("cannot get domain details"));
-        return (NULL);
+        return NULL;
     }

     if (XEN_GETDOMAININFO_DOMAIN(dominfo) != dom->id) {
         virXenError(VIR_ERR_INTERNAL_ERROR, "%s",
                     _("cannot get domain details"));
-        return (NULL);
+        return NULL;
     }

     if (XEN_GETDOMAININFO_FLAGS(dominfo) & DOMFLAGS_HVM)
@@ -2995,21 +2995,21 @@ xenHypervisorLookupDomainByID(virConnectPtr conn,

     priv = (xenUnifiedPrivatePtr) conn->privateData;
     if (priv->handle < 0)
-        return (NULL);
+        return NULL;

     XEN_GETDOMAININFO_CLEAR(dominfo);

     if (virXen_getdomaininfo(priv->handle, id, &dominfo) < 0)
-        return (NULL);
+        return NULL;

     if (XEN_GETDOMAININFO_DOMAIN(dominfo) != id)
-        return (NULL);
+        return NULL;

     xenUnifiedLock(priv);
     name = xenStoreDomainGetName(conn, id);
     xenUnifiedUnlock(priv);
     if (!name)
-        return (NULL);
+        return NULL;

     ret = virGetDomain(conn, name, XEN_GETDOMAININFO_UUID(dominfo));
     if (ret)
@@ -3031,12 +3031,12 @@ xenHypervisorLookupDomainByUUID(virConnectPtr conn,

     priv = (xenUnifiedPrivatePtr) conn->privateData;
     if (priv->handle < 0)
-        return (NULL);
+        return NULL;

  retry:
     if (!(XEN_GETDOMAININFOLIST_ALLOC(dominfos, maxids))) {
         virReportOOMError();
-        return(NULL);
+        return NULL;
     }

     XEN_GETDOMAININFOLIST_CLEAR(dominfos, maxids);
@@ -3045,7 +3045,7 @@ xenHypervisorLookupDomainByUUID(virConnectPtr conn,

     if (nids < 0) {
         XEN_GETDOMAININFOLIST_FREE(dominfos);
-        return (NULL);
+        return NULL;
     }

     /* Can't possibly have more than 65,000 concurrent guests
@@ -3059,7 +3059,7 @@ xenHypervisorLookupDomainByUUID(virConnectPtr conn,
             maxids *= 2;
             goto retry;
         }
-        return (NULL);
+        return NULL;
     }

     id = -1;
@@ -3072,13 +3072,13 @@ xenHypervisorLookupDomainByUUID(virConnectPtr conn,
     XEN_GETDOMAININFOLIST_FREE(dominfos);

     if (id == -1)
-        return (NULL);
+        return NULL;

     xenUnifiedLock(priv);
     name = xenStoreDomainGetName(conn, id);
     xenUnifiedUnlock(priv);
     if (!name)
-        return (NULL);
+        return NULL;

     ret = virGetDomain(conn, name, uuid);
     if (ret)
@@ -3102,7 +3102,7 @@ xenHypervisorGetMaxVcpus(virConnectPtr conn,
         return -1;
     priv = (xenUnifiedPrivatePtr) conn->privateData;
     if (priv->handle < 0)
-        return (-1);
+        return -1;

     return MAX_VIRT_CPUS;
 }
@@ -3142,9 +3142,9 @@ xenHypervisorGetDomMaxMemory(virConnectPtr conn, int id)
     ret = virXen_getdomaininfo(priv->handle, id, &dominfo);

     if ((ret < 0) || (XEN_GETDOMAININFO_DOMAIN(dominfo) != id))
-        return (0);
+        return 0;

-    return((unsigned long) XEN_GETDOMAININFO_MAX_PAGES(dominfo) * kb_per_pages);
+    return (unsigned long) XEN_GETDOMAININFO_MAX_PAGES(dominfo) * kb_per_pages;
 }

 /**
@@ -3167,9 +3167,9 @@ xenHypervisorGetMaxMemory(virDomainPtr domain)

     priv = (xenUnifiedPrivatePtr) domain->conn->privateData;
     if (priv->handle < 0 || domain->id < 0)
-        return (0);
+        return 0;

-    return(xenHypervisorGetDomMaxMemory(domain->conn, domain->id));
+    return xenHypervisorGetDomMaxMemory(domain->conn, domain->id);
 }

 /**
@@ -3201,7 +3201,7 @@ xenHypervisorGetDomInfo(virConnectPtr conn, int id, virDomainInfoPtr info)

     priv = (xenUnifiedPrivatePtr) conn->privateData;
     if (priv->handle < 0 || info == NULL)
-        return (-1);
+        return -1;

     memset(info, 0, sizeof(virDomainInfo));
     XEN_GETDOMAININFO_CLEAR(dominfo);
@@ -3209,7 +3209,7 @@ xenHypervisorGetDomInfo(virConnectPtr conn, int id, virDomainInfoPtr info)
     ret = virXen_getdomaininfo(priv->handle, id, &dominfo);

     if ((ret < 0) || (XEN_GETDOMAININFO_DOMAIN(dominfo) != id))
-        return (-1);
+        return -1;

     domain_flags = XEN_GETDOMAININFO_FLAGS(dominfo);
     domain_flags &= ~DOMFLAGS_HVM; /* Mask out HVM flags */
@@ -3253,7 +3253,7 @@ xenHypervisorGetDomInfo(virConnectPtr conn, int id, virDomainInfoPtr info)
     if(info->maxMem != UINT_MAX)
         info->maxMem *= kb_per_pages;
     info->nrVirtCpu = XEN_GETDOMAININFO_CPUCOUNT(dominfo);
-    return (0);
+    return 0;
 }

 /**
@@ -3276,9 +3276,9 @@ xenHypervisorGetDomainInfo(virDomainPtr domain, virDomainInfoPtr info)
     priv = (xenUnifiedPrivatePtr) domain->conn->privateData;
     if (priv->handle < 0 || info == NULL ||
         (domain->id < 0))
-        return (-1);
+        return -1;

-    return(xenHypervisorGetDomInfo(domain->conn, domain->id, info));
+    return xenHypervisorGetDomInfo(domain->conn, domain->id, info);

 }

@@ -3355,7 +3355,7 @@ xenHypervisorNodeGetCellsFreeMemory(virConnectPtr conn, unsigned long long *free
     if (priv->nbNodeCells < 0) {
         virXenError(VIR_ERR_XEN_CALL, "%s",
                     _("cannot determine actual number of cells"));
-        return(-1);
+        return -1;
     }

     if ((maxCells < 1) || (startCell >= priv->nbNodeCells)) {
@@ -3389,14 +3389,14 @@ xenHypervisorNodeGetCellsFreeMemory(virConnectPtr conn, unsigned long long *free
             op_sys.u.availheap.node = i;
         ret = xenHypervisorDoV2Sys(priv->handle, &op_sys);
         if (ret < 0) {
-            return(-1);
+            return -1;
         }
         if (hv_versions.sys_interface >= 5)
             freeMems[j] = op_sys.u.availheap5.avail_bytes;
         else
             freeMems[j] = op_sys.u.availheap.avail_bytes;
     }
-    return (j);
+    return j;
 }


@@ -3419,12 +3419,12 @@ xenHypervisorPauseDomain(virDomainPtr domain)

     priv = (xenUnifiedPrivatePtr) domain->conn->privateData;
     if (priv->handle < 0 || domain->id < 0)
-        return (-1);
+        return -1;

     ret = virXen_pausedomain(priv->handle, domain->id);
     if (ret < 0)
-        return (-1);
-    return (0);
+        return -1;
+    return 0;
 }

 /**
@@ -3446,12 +3446,12 @@ xenHypervisorResumeDomain(virDomainPtr domain)

     priv = (xenUnifiedPrivatePtr) domain->conn->privateData;
     if (priv->handle < 0 || domain->id < 0)
-        return (-1);
+        return -1;

     ret = virXen_unpausedomain(priv->handle, domain->id);
     if (ret < 0)
-        return (-1);
-    return (0);
+        return -1;
+    return 0;
 }

 /**
@@ -3480,12 +3480,12 @@ xenHypervisorDestroyDomainFlags(virDomainPtr domain,

     priv = (xenUnifiedPrivatePtr) domain->conn->privateData;
     if (priv->handle < 0 || domain->id < 0)
-        return (-1);
+        return -1;

     ret = virXen_destroydomain(priv->handle, domain->id);
     if (ret < 0)
-        return (-1);
-    return (0);
+        return -1;
+    return 0;
 }

 /**
@@ -3508,12 +3508,12 @@ xenHypervisorSetMaxMemory(virDomainPtr domain, unsigned long memory)

     priv = (xenUnifiedPrivatePtr) domain->conn->privateData;
     if (priv->handle < 0 || domain->id < 0)
-        return (-1);
+        return -1;

     ret = virXen_setmaxmem(priv->handle, domain->id, memory);
     if (ret < 0)
-        return (-1);
-    return (0);
+        return -1;
+    return 0;
 }


@@ -3538,12 +3538,12 @@ xenHypervisorSetVcpus(virDomainPtr domain, unsigned int nvcpus)

     priv = (xenUnifiedPrivatePtr) domain->conn->privateData;
     if (priv->handle < 0 || domain->id < 0 || nvcpus < 1)
-        return (-1);
+        return -1;

     ret = virXen_setmaxvcpus(priv->handle, domain->id, nvcpus);
     if (ret < 0)
-        return (-1);
-    return (0);
+        return -1;
+    return 0;
 }

 /**
@@ -3571,13 +3571,13 @@ xenHypervisorPinVcpu(virDomainPtr domain, unsigned int vcpu,
     priv = (xenUnifiedPrivatePtr) domain->conn->privateData;
     if (priv->handle < 0 || (domain->id < 0) ||
         (cpumap == NULL) || (maplen < 1))
-        return (-1);
+        return -1;

     ret = virXen_setvcpumap(priv->handle, domain->id, vcpu,
                             cpumap, maplen);
     if (ret < 0)
-        return (-1);
-    return (0);
+        return -1;
+    return 0;
 }

 /**
@@ -3618,7 +3618,7 @@ xenHypervisorGetVcpus(virDomainPtr domain, virVcpuInfoPtr info, int maxinfo,
         (sizeof(cpumap_t) & 7)) {
         virXenError(VIR_ERR_INTERNAL_ERROR, "%s",
                     _("domain shut off or invalid"));
-        return (-1);
+        return -1;
     }
     if ((cpumaps != NULL) && (maplen < 1)) {
         virXenError(VIR_ERR_INVALID_ARG, "%s",
@@ -3633,7 +3633,7 @@ xenHypervisorGetVcpus(virDomainPtr domain, virVcpuInfoPtr info, int maxinfo,
     if ((ret < 0) || (XEN_GETDOMAININFO_DOMAIN(dominfo) != domain->id)) {
         virXenError(VIR_ERR_INTERNAL_ERROR, "%s",
                     _("cannot get domain details"));
-        return (-1);
+        return -1;
     }
     nbinfo = XEN_GETDOMAININFO_CPUCOUNT(dominfo) + 1;
     if (nbinfo > maxinfo) nbinfo = maxinfo;
@@ -3650,7 +3650,7 @@ xenHypervisorGetVcpus(virDomainPtr domain, virVcpuInfoPtr info, int maxinfo,
             if (ret < 0) {
                 virXenError(VIR_ERR_INTERNAL_ERROR, "%s",
                             _("cannot get VCPUs info"));
-                return(-1);
+                return -1;
             }
         } else {
             ret = virXen_getvcpusinfo(priv->handle, domain->id, i,
@@ -3658,7 +3658,7 @@ xenHypervisorGetVcpus(virDomainPtr domain, virVcpuInfoPtr info, int maxinfo,
             if (ret < 0) {
                 virXenError(VIR_ERR_INTERNAL_ERROR, "%s",
                             _("cannot get VCPUs info"));
-                return(-1);
+                return -1;
             }
         }
     }
@@ -3686,7 +3686,7 @@ xenHypervisorGetVcpuMax(virDomainPtr domain)

     priv = (xenUnifiedPrivatePtr) domain->conn->privateData;
     if (priv->handle < 0)
-        return (-1);
+        return -1;

     /* inactive domain */
     if (domain->id < 0) {
@@ -3697,7 +3697,7 @@ xenHypervisorGetVcpuMax(virDomainPtr domain)
                                    &dominfo);

         if ((ret < 0) || (XEN_GETDOMAININFO_DOMAIN(dominfo) != domain->id))
-            return (-1);
+            return -1;
         maxcpu = XEN_GETDOMAININFO_MAXCPUID(dominfo) + 1;
     }

diff --git a/src/xen/xend_internal.c b/src/xen/xend_internal.c
index a19d055..46ca2ba 100644
--- a/src/xen/xend_internal.c
+++ b/src/xen/xend_internal.c
@@ -162,7 +162,7 @@ wr_sync(int fd, void *buffer, size_t size, int do_read)
                 virXendError(VIR_ERR_INTERNAL_ERROR,
                              "%s", _("failed to write to Xen Daemon"));

-            return (-1);
+            return -1;
         }

         offset += len;
@@ -234,7 +234,7 @@ sreads(int fd, char *buffer, size_t n_buffer)
     size_t offset;

     if (n_buffer < 1)
-        return (-1);
+        return -1;

     for (offset = 0; offset < (n_buffer - 1); offset++) {
         ssize_t ret;
@@ -620,7 +620,7 @@ xenDaemonOpen_unix(virConnectPtr conn, const char *path)
     xenUnifiedPrivatePtr priv;

     if ((conn == NULL) || (path == NULL))
-        return (-1);
+        return -1;

     priv = (xenUnifiedPrivatePtr) conn->privateData;
     memset(&priv->addr, 0, sizeof(priv->addr));
@@ -638,7 +638,7 @@ xenDaemonOpen_unix(virConnectPtr conn, const char *path)
     if (virStrcpyStatic(addr->sun_path, path) == NULL)
         return -1;

-    return (0);
+    return 0;
 }


@@ -663,7 +663,7 @@ xenDaemonOpen_tcp(virConnectPtr conn, const char *host, const char *port)
     int ret;

     if ((conn == NULL) || (host == NULL) || (port == NULL))
-        return (-1);
+        return -1;

     priv = (xenUnifiedPrivatePtr) conn->privateData;

@@ -869,7 +869,7 @@ xenDaemonDomainLookupByName_ids(virConnectPtr xend, const char *domname,

   error:
     sexpr_free(root);
-    return (ret);
+    return ret;
 }


@@ -920,13 +920,13 @@ xenDaemonDomainLookupByID(virConnectPtr xend,
     }

     sexpr_free(root);
-    return (0);
+    return 0;

 error:
     sexpr_free(root);
     if (domname)
         VIR_FREE(*domname);
-    return (-1);
+    return -1;
 }


@@ -938,14 +938,14 @@ xend_detect_config_version(virConnectPtr conn) {

     if (!VIR_IS_CONNECT(conn)) {
         virXendError(VIR_ERR_INVALID_CONN, __FUNCTION__);
-        return (-1);
+        return -1;
     }

     priv = (xenUnifiedPrivatePtr) conn->privateData;

     root = sexpr_get(conn, "/xend/node/");
     if (root == NULL)
-        return (-1);
+        return -1;

     value = sexpr_node(root, "node/xend_config_format");

@@ -957,7 +957,7 @@ xend_detect_config_version(virConnectPtr conn) {
         priv->xendConfigVersion = XEND_CONFIG_VERSION_3_0_2;
     }
     sexpr_free(root);
-    return (0);
+    return 0;
 }


@@ -1015,7 +1015,7 @@ sexpr_to_xend_domain_info(virDomainPtr domain, const struct sexpr *root,
     int vcpus;

     if ((root == NULL) || (info == NULL))
-        return (-1);
+        return -1;

     info->state = sexpr_to_xend_domain_state(domain, root);
     info->memory = sexpr_u64(root, "domain/memory") << 10;
@@ -1027,7 +1027,7 @@ sexpr_to_xend_domain_info(virDomainPtr domain, const struct sexpr *root,
     if (!info->nrVirtCpu || vcpus < info->nrVirtCpu)
         info->nrVirtCpu = vcpus;

-    return (0);
+    return 0;
 }

 /**
@@ -1047,7 +1047,7 @@ sexpr_to_xend_node_info(const struct sexpr *root, virNodeInfoPtr info)


     if ((root == NULL) || (info == NULL))
-        return (-1);
+        return -1;

     machine = sexpr_node(root, "node/machine");
     if (machine == NULL) {
@@ -1074,7 +1074,7 @@ sexpr_to_xend_node_info(const struct sexpr *root, virNodeInfoPtr info)
         int nr_cpus = sexpr_int(root, "node/nr_cpus");
         int procs = info->nodes * info->cores * info->threads;
         if (procs == 0) /* Sanity check in case of Xen bugs in futures..*/
-            return (-1);
+            return -1;
         info->sockets = nr_cpus / procs;
     }

@@ -1091,7 +1091,7 @@ sexpr_to_xend_node_info(const struct sexpr *root, virNodeInfoPtr info)
         info->sockets = info->cpus / (info->cores * info->threads);
     }

-    return (0);
+    return 0;
 }


@@ -1170,7 +1170,7 @@ sexpr_to_xend_topology(const struct sexpr *root,
     }
     VIR_FREE(cpuNums);
     VIR_FREE(cpuset);
-    return (0);
+    return 0;

   parse_error:
     virXendError(VIR_ERR_XEN_CALL, "%s", _("topology syntax error"));
@@ -1178,13 +1178,13 @@ sexpr_to_xend_topology(const struct sexpr *root,
     VIR_FREE(cpuNums);
     VIR_FREE(cpuset);

-    return (-1);
+    return -1;

   memory_error:
     VIR_FREE(cpuNums);
     VIR_FREE(cpuset);
     virReportOOMError();
-    return (-1);
+    return -1;
 }


@@ -1207,7 +1207,7 @@ sexpr_to_domain(virConnectPtr conn, const struct sexpr *root)
     xenUnifiedPrivatePtr priv;

     if ((conn == NULL) || (root == NULL))
-        return(NULL);
+        return NULL;

     priv = (xenUnifiedPrivatePtr) conn->privateData;

@@ -1232,14 +1232,14 @@ sexpr_to_domain(virConnectPtr conn, const struct sexpr *root)
     else
         ret->id = -1; /* An inactive domain */

-    return (ret);
+    return ret;

 error:
     virXendError(VIR_ERR_INTERNAL_ERROR,
                  "%s", _("failed to parse Xend domain information"));
     if (ret != NULL)
         virUnrefDomain(ret);
-    return(NULL);
+    return NULL;
 }


@@ -1357,13 +1357,13 @@ xenDaemonDomainSuspend(virDomainPtr domain)
 {
     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL)) {
         virXendError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(-1);
+        return -1;
     }

     if (domain->id < 0) {
         virXendError(VIR_ERR_OPERATION_INVALID,
                      _("Domain %s isn't running."), domain->name);
-        return(-1);
+        return -1;
     }

     return xend_op(domain->conn, domain->name, "op", "pause", NULL);
@@ -1383,13 +1383,13 @@ xenDaemonDomainResume(virDomainPtr domain)
 {
     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL)) {
         virXendError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(-1);
+        return -1;
     }

     if (domain->id < 0) {
         virXendError(VIR_ERR_OPERATION_INVALID,
                      _("Domain %s isn't running."), domain->name);
-        return(-1);
+        return -1;
     }

     return xend_op(domain->conn, domain->name, "op", "unpause", NULL);
@@ -1410,13 +1410,13 @@ xenDaemonDomainShutdown(virDomainPtr domain)
 {
     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL)) {
         virXendError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(-1);
+        return -1;
     }

     if (domain->id < 0) {
         virXendError(VIR_ERR_OPERATION_INVALID,
                      _("Domain %s isn't running."), domain->name);
-        return(-1);
+        return -1;
     }

     return xend_op(domain->conn, domain->name, "op", "shutdown", "reason", "poweroff", NULL);
@@ -1440,13 +1440,13 @@ xenDaemonDomainReboot(virDomainPtr domain, unsigned int flags)

     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL)) {
         virXendError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(-1);
+        return -1;
     }

     if (domain->id < 0) {
         virXendError(VIR_ERR_OPERATION_INVALID,
                      _("Domain %s isn't running."), domain->name);
-        return(-1);
+        return -1;
     }

     return xend_op(domain->conn, domain->name, "op", "shutdown", "reason", "reboot", NULL);
@@ -1477,13 +1477,13 @@ xenDaemonDomainDestroyFlags(virDomainPtr domain,

     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL)) {
         virXendError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(-1);
+        return -1;
     }

     if (domain->id < 0) {
         virXendError(VIR_ERR_OPERATION_INVALID,
                      _("Domain %s isn't running."), domain->name);
-        return(-1);
+        return -1;
     }

     return xend_op(domain->conn, domain->name, "op", "destroy", NULL);
@@ -1507,18 +1507,18 @@ xenDaemonDomainGetOSType(virDomainPtr domain)

     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL)) {
         virXendError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(NULL);
+        return NULL;
     }

     priv = (xenUnifiedPrivatePtr) domain->conn->privateData;

     if (domain->id < 0 && priv->xendConfigVersion < XEND_CONFIG_VERSION_3_0_4)
-        return(NULL);
+        return NULL;

     /* can we ask for a subset ? worth it ? */
     root = sexpr_get(domain->conn, "/xend/domain/%s?detail=1", domain->name);
     if (root == NULL)
-        return(NULL);
+        return NULL;

     if (sexpr_lookup(root, "domain/image/hvm")) {
         type = strdup("hvm");
@@ -1531,7 +1531,7 @@ xenDaemonDomainGetOSType(virDomainPtr domain)

     sexpr_free(root);

-    return(type);
+    return type;
 }

 /**
@@ -1553,18 +1553,18 @@ xenDaemonDomainSave(virDomainPtr domain, const char *filename)
     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL) ||
         (filename == NULL)) {
         virXendError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(-1);
+        return -1;
     }

     if (domain->id < 0) {
         virXendError(VIR_ERR_OPERATION_INVALID,
                      _("Domain %s isn't running."), domain->name);
-        return(-1);
+        return -1;
     }

     /* We can't save the state of Domain-0, that would mean stopping it too */
     if (domain->id == 0) {
-        return(-1);
+        return -1;
     }

     return xend_op(domain->conn, domain->name, "op", "save", "file", filename, NULL);
@@ -1591,13 +1591,13 @@ xenDaemonDomainCoreDump(virDomainPtr domain, const char *filename,
     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL) ||
         (filename == NULL)) {
         virXendError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(-1);
+        return -1;
     }

     if (domain->id < 0) {
         virXendError(VIR_ERR_OPERATION_INVALID,
                      _("Domain %s isn't running."), domain->name);
-        return(-1);
+        return -1;
     }

     return xend_op(domain->conn, domain->name,
@@ -1624,7 +1624,7 @@ xenDaemonDomainRestore(virConnectPtr conn, const char *filename)
     if ((conn == NULL) || (filename == NULL)) {
         /* this should be caught at the interface but ... */
         virXendError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return (-1);
+        return -1;
     }
     return xend_op(conn, "", "op", "restore", "file", filename, NULL);
 }
@@ -1686,13 +1686,13 @@ xenDaemonDomainSetMaxMemory(virDomainPtr domain, unsigned long memory)

     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL)) {
         virXendError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(-1);
+        return -1;
     }

     priv = (xenUnifiedPrivatePtr) domain->conn->privateData;

     if (domain->id < 0 && priv->xendConfigVersion < XEND_CONFIG_VERSION_3_0_4)
-        return(-1);
+        return -1;

     snprintf(buf, sizeof(buf), "%lu", VIR_DIV_UP(memory, 1024));
     return xend_op(domain->conn, domain->name, "op", "maxmem_set", "memory",
@@ -1723,13 +1723,13 @@ xenDaemonDomainSetMemory(virDomainPtr domain, unsigned long memory)

     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL)) {
         virXendError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(-1);
+        return -1;
     }

     priv = (xenUnifiedPrivatePtr) domain->conn->privateData;

     if (domain->id < 0 && priv->xendConfigVersion < XEND_CONFIG_VERSION_3_0_4)
-        return(-1);
+        return -1;

     snprintf(buf, sizeof(buf), "%lu", VIR_DIV_UP(memory, 1024));
     return xend_op(domain->conn, domain->name, "op", "mem_target_set",
@@ -1755,7 +1755,7 @@ xenDaemonDomainFetch(virConnectPtr conn,
     else
         root = sexpr_get(conn, "/xend/domain/%d?detail=1", domid);
     if (root == NULL)
-        return (NULL);
+        return NULL;

     priv = (xenUnifiedPrivatePtr) conn->privateData;

@@ -1777,7 +1777,7 @@ xenDaemonDomainFetch(virConnectPtr conn,
 cleanup:
     sexpr_free(root);

-    return (def);
+    return def;
 }


@@ -1804,20 +1804,20 @@ xenDaemonDomainGetXMLDesc(virDomainPtr domain, unsigned int flags,

     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL)) {
         virXendError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(NULL);
+        return NULL;
     }
     priv = (xenUnifiedPrivatePtr) domain->conn->privateData;

     if (domain->id < 0 && priv->xendConfigVersion < XEND_CONFIG_VERSION_3_0_4) {
         /* fall-through to the next driver to handle */
-        return(NULL);
+        return NULL;
     }

     if (!(def = xenDaemonDomainFetch(domain->conn,
                                      domain->id,
                                      domain->name,
                                      cpus)))
-        return(NULL);
+        return NULL;

     xml = virDomainDefFormat(def, flags);

@@ -1847,21 +1847,21 @@ xenDaemonDomainGetInfo(virDomainPtr domain, virDomainInfoPtr info)
     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL) ||
         (info == NULL)) {
         virXendError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(-1);
+        return -1;
     }

     priv = (xenUnifiedPrivatePtr) domain->conn->privateData;

     if (domain->id < 0 && priv->xendConfigVersion < XEND_CONFIG_VERSION_3_0_4)
-        return(-1);
+        return -1;

     root = sexpr_get(domain->conn, "/xend/domain/%s?detail=1", domain->name);
     if (root == NULL)
-        return (-1);
+        return -1;

     ret = sexpr_to_xend_domain_info(domain, root, info);
     sexpr_free(root);
-    return (ret);
+    return ret;
 }


@@ -1922,7 +1922,7 @@ xenDaemonLookupByName(virConnectPtr conn, const char *domname)

     if ((conn == NULL) || (domname == NULL)) {
         virXendError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(NULL);
+        return NULL;
     }

     root = sexpr_get(conn, "/xend/domain/%s?detail=1", domname);
@@ -1933,7 +1933,7 @@ xenDaemonLookupByName(virConnectPtr conn, const char *domname)

 error:
     sexpr_free(root);
-    return(ret);
+    return ret;
 }


@@ -1953,20 +1953,20 @@ xenDaemonNodeGetInfo(virConnectPtr conn, virNodeInfoPtr info) {

     if (!VIR_IS_CONNECT(conn)) {
         virXendError(VIR_ERR_INVALID_CONN, __FUNCTION__);
-        return (-1);
+        return -1;
     }
     if (info == NULL) {
         virXendError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return (-1);
+        return -1;
     }

     root = sexpr_get(conn, "/xend/node/");
     if (root == NULL)
-        return (-1);
+        return -1;

     ret = sexpr_to_xend_node_info(root, info);
     sexpr_free(root);
-    return (ret);
+    return ret;
 }

 /**
@@ -1986,22 +1986,22 @@ xenDaemonNodeGetTopology(virConnectPtr conn,

     if (!VIR_IS_CONNECT(conn)) {
         virXendError(VIR_ERR_INVALID_CONN, __FUNCTION__);
-        return (-1);
+        return -1;
     }

     if (caps == NULL) {
         virXendError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return (-1);
+        return -1;
     }

     root = sexpr_get(conn, "/xend/node/");
     if (root == NULL) {
-        return (-1);
+        return -1;
     }

     ret = sexpr_to_xend_topology(root, caps);
     sexpr_free(root);
-    return (ret);
+    return ret;
 }

 /**
@@ -2024,22 +2024,22 @@ xenDaemonGetVersion(virConnectPtr conn, unsigned long *hvVer)

     if (!VIR_IS_CONNECT(conn)) {
         virXendError(VIR_ERR_INVALID_CONN, __FUNCTION__);
-        return (-1);
+        return -1;
     }
     if (hvVer == NULL) {
         virXendError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return (-1);
+        return -1;
     }
     root = sexpr_get(conn, "/xend/node/");
     if (root == NULL)
-        return(-1);
+        return -1;

     major = sexpr_int(root, "node/xen_major");
     minor = sexpr_int(root, "node/xen_minor");
     sexpr_free(root);
     version = major * 1000000 + minor * 1000;
     *hvVer = version;
-    return(0);
+    return 0;
 }


@@ -2064,7 +2064,7 @@ xenDaemonListDomains(virConnectPtr conn, int *ids, int maxids)
     long id;

     if (maxids == 0)
-        return(0);
+        return 0;

     if ((ids == NULL) || (maxids < 0))
         goto error;
@@ -2087,7 +2087,7 @@ xenDaemonListDomains(virConnectPtr conn, int *ids, int maxids)

 error:
     sexpr_free(root);
-    return(ret);
+    return ret;
 }

 /**
@@ -2120,7 +2120,7 @@ xenDaemonNumOfDomains(virConnectPtr conn)

 error:
     sexpr_free(root);
-    return(ret);
+    return ret;
 }


@@ -2148,11 +2148,11 @@ xenDaemonLookupByID(virConnectPtr conn, int id) {

     ret->id = id;
     VIR_FREE(name);
-    return (ret);
+    return ret;

  error:
     VIR_FREE(name);
-    return (NULL);
+    return NULL;
 }

 /**
@@ -2181,7 +2181,7 @@ xenDaemonDomainSetVcpusFlags(virDomainPtr domain, unsigned int vcpus,
     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL)
         || (vcpus < 1)) {
         virXendError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return (-1);
+        return -1;
     }

     priv = (xenUnifiedPrivatePtr) domain->conn->privateData;
@@ -2263,7 +2263,7 @@ xenDaemonDomainPinVcpu(virDomainPtr domain, unsigned int vcpu,
     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL)
      || (cpumap == NULL) || (maplen < 1) || (maplen > (int)sizeof(cpumap_t))) {
         virXendError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return (-1);
+        return -1;
     }

     priv = (xenUnifiedPrivatePtr) domain->conn->privateData;
@@ -2300,7 +2300,7 @@ xenDaemonDomainPinVcpu(virDomainPtr domain, unsigned int vcpu,
         if (virDomainVcpuPinAdd(def, cpumap, maplen, vcpu) < 0) {
             virXendError(VIR_ERR_INTERNAL_ERROR,
                          "%s", _("failed to add vcpupin xml entry"));
-            return (-1);
+            return -1;
         }
     }

@@ -2399,16 +2399,16 @@ xenDaemonDomainGetVcpus(virDomainPtr domain, virVcpuInfoPtr info, int maxinfo,
     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL)
         || (info == NULL) || (maxinfo < 1)) {
         virXendError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return (-1);
+        return -1;
     }
     if (cpumaps != NULL && maplen < 1) {
         virXendError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return (-1);
+        return -1;
     }

     root = sexpr_get(domain->conn, "/xend/domain/%s?op=vcpuinfo", domain->name);
     if (root == NULL)
-        return (-1);
+        return -1;

     if (cpumaps != NULL)
         memset(cpumaps, 0, maxinfo * maplen);
@@ -2456,7 +2456,7 @@ xenDaemonDomainGetVcpus(virDomainPtr domain, virVcpuInfoPtr info, int maxinfo,
         }
     }
     sexpr_free(root);
-    return(nbinfo);
+    return nbinfo;
 }

 /**
@@ -2484,7 +2484,7 @@ xenDaemonLookupByUUID(virConnectPtr conn, const unsigned char *uuid)
         tmp = names;

         if (names == NULL) {
-            return (NULL);
+            return NULL;
         }
         while (*tmp != NULL) {
             id = xenDaemonDomainLookupByName_ids(conn, *tmp, &ident[0]);
@@ -2511,7 +2511,7 @@ xenDaemonLookupByUUID(virConnectPtr conn, const unsigned char *uuid)
         virUUIDFormat(uuid, uuidstr);
         root = sexpr_get(conn, "/xend/domain/%s?detail=1", uuidstr);
         if (root == NULL)
-            return (NULL);
+            return NULL;
         domname = (char*)sexpr_node(root, "domain/name");
         if (sexpr_node(root, "domain/domid")) /* only active domains have domid */
             id = sexpr_int(root, "domain/domid");
@@ -2529,7 +2529,7 @@ xenDaemonLookupByUUID(virConnectPtr conn, const unsigned char *uuid)
     }

     if (name == NULL)
-        return (NULL);
+        return NULL;

     ret = virGetDomain(conn, name, uuid);
     if (ret == NULL) goto cleanup;
@@ -2538,7 +2538,7 @@ xenDaemonLookupByUUID(virConnectPtr conn, const unsigned char *uuid)

   cleanup:
     VIR_FREE(name);
-    return (ret);
+    return ret;
 }

 /**
@@ -2570,11 +2570,11 @@ xenDaemonCreateXML(virConnectPtr conn, const char *xmlDesc,
     if (!(def = virDomainDefParseString(priv->caps, xmlDesc,
                                         1 << VIR_DOMAIN_VIRT_XEN,
                                         VIR_DOMAIN_XML_INACTIVE)))
-        return (NULL);
+        return NULL;

     if (!(sexpr = xenFormatSxpr(conn, def, priv->xendConfigVersion))) {
         virDomainDefFree(def);
-        return (NULL);
+        return NULL;
     }

     ret = xenDaemonDomainCreateXML(conn, sexpr);
@@ -2595,7 +2595,7 @@ xenDaemonCreateXML(virConnectPtr conn, const char *xmlDesc,
         goto error;

     virDomainDefFree(def);
-    return (dom);
+    return dom;

   error:
     /* Make sure we don't leave a still-born domain around */
@@ -2604,7 +2604,7 @@ xenDaemonCreateXML(virConnectPtr conn, const char *xmlDesc,
         virUnrefDomain(dom);
     }
     virDomainDefFree(def);
-    return (NULL);
+    return NULL;
 }

 /**
@@ -2916,7 +2916,7 @@ xenDaemonDetachDeviceFlags(virDomainPtr domain, const char *xml,

     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL)) {
         virXendError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return (-1);
+        return -1;
     }

     priv = (xenUnifiedPrivatePtr) domain->conn->privateData;
@@ -3009,7 +3009,7 @@ xenDaemonDomainGetAutostart(virDomainPtr domain,

     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL)) {
         virXendError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return (-1);
+        return -1;
     }

     /* xm_internal.c (the support for defined domains from /etc/xen
@@ -3017,13 +3017,13 @@ xenDaemonDomainGetAutostart(virDomainPtr domain,
      */
     priv = (xenUnifiedPrivatePtr) domain->conn->privateData;
     if (priv->xendConfigVersion < XEND_CONFIG_VERSION_3_0_4)
-        return(-1);
+        return -1;

     root = sexpr_get(domain->conn, "/xend/domain/%s?detail=1", domain->name);
     if (root == NULL) {
         virXendError(VIR_ERR_XEN_CALL,
                       "%s", _("xenDaemonGetAutostart failed to find this domain"));
-        return (-1);
+        return -1;
     }

     *autostart = 0;
@@ -3049,7 +3049,7 @@ xenDaemonDomainSetAutostart(virDomainPtr domain,

     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL)) {
         virXendError(VIR_ERR_INTERNAL_ERROR, __FUNCTION__);
-        return (-1);
+        return -1;
     }

     /* xm_internal.c (the support for defined domains from /etc/xen
@@ -3057,13 +3057,13 @@ xenDaemonDomainSetAutostart(virDomainPtr domain,
      */
     priv = (xenUnifiedPrivatePtr) domain->conn->privateData;
     if (priv->xendConfigVersion < XEND_CONFIG_VERSION_3_0_4)
-        return(-1);
+        return -1;

     root = sexpr_get(domain->conn, "/xend/domain/%s?detail=1", domain->name);
     if (root == NULL) {
         virXendError(VIR_ERR_XEN_CALL,
                       "%s", _("xenDaemonSetAutostart failed to find this domain"));
-        return (-1);
+        return -1;
     }

     autonode = sexpr_lookup(root, "domain/on_xend_start");
@@ -3319,14 +3319,14 @@ virDomainPtr xenDaemonDomainDefineXML(virConnectPtr conn, const char *xmlDesc) {
     priv = (xenUnifiedPrivatePtr) conn->privateData;

     if (priv->xendConfigVersion < XEND_CONFIG_VERSION_3_0_4)
-        return(NULL);
+        return NULL;

     if (!(def = virDomainDefParseString(priv->caps, xmlDesc,
                                         1 << VIR_DOMAIN_VIRT_XEN,
                                         VIR_DOMAIN_XML_INACTIVE))) {
         virXendError(VIR_ERR_XML_ERROR,
                      "%s", _("failed to parse domain description"));
-        return (NULL);
+        return NULL;
     }

     if (!(sexpr = xenFormatSxpr(conn, def, priv->xendConfigVersion))) {
@@ -3348,11 +3348,11 @@ virDomainPtr xenDaemonDomainDefineXML(virConnectPtr conn, const char *xmlDesc) {
         goto error;
     }
     virDomainDefFree(def);
-    return (dom);
+    return dom;

   error:
     virDomainDefFree(def);
-    return (NULL);
+    return NULL;
 }
 int xenDaemonDomainCreate(virDomainPtr domain)
 {
@@ -3362,13 +3362,13 @@ int xenDaemonDomainCreate(virDomainPtr domain)

     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL)) {
         virXendError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(-1);
+        return -1;
     }

     priv = (xenUnifiedPrivatePtr) domain->conn->privateData;

     if (priv->xendConfigVersion < XEND_CONFIG_VERSION_3_0_4)
-        return(-1);
+        return -1;

     ret = xend_op(domain->conn, domain->name, "op", "start", NULL);

@@ -3389,13 +3389,13 @@ int xenDaemonDomainUndefine(virDomainPtr domain)

     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL)) {
         virXendError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(-1);
+        return -1;
     }

     priv = (xenUnifiedPrivatePtr) domain->conn->privateData;

     if (priv->xendConfigVersion < XEND_CONFIG_VERSION_3_0_4)
-        return(-1);
+        return -1;

     return xend_op(domain->conn, domain->name, "op", "delete", NULL);
 }
@@ -3420,7 +3420,7 @@ xenDaemonNumOfDefinedDomains(virConnectPtr conn)
      * config files used by old Xen) will handle this.
      */
     if (priv->xendConfigVersion < XEND_CONFIG_VERSION_3_0_4)
-        return(-1);
+        return -1;

     root = sexpr_get(conn, "/xend/domain?state=halted");
     if (root == NULL)
@@ -3437,7 +3437,7 @@ xenDaemonNumOfDefinedDomains(virConnectPtr conn)

 error:
     sexpr_free(root);
-    return(ret);
+    return ret;
 }

 static int
@@ -3448,12 +3448,12 @@ xenDaemonListDefinedDomains(virConnectPtr conn, char **const names, int maxnames
     xenUnifiedPrivatePtr priv = (xenUnifiedPrivatePtr) conn->privateData;

     if (priv->xendConfigVersion < XEND_CONFIG_VERSION_3_0_4)
-        return(-1);
+        return -1;

     if ((names == NULL) || (maxnames < 0))
         goto error;
     if (maxnames == 0)
-        return(0);
+        return 0;

     root = sexpr_get(conn, "/xend/domain?state=halted");
     if (root == NULL)
@@ -3477,7 +3477,7 @@ xenDaemonListDefinedDomains(virConnectPtr conn, char **const names, int maxnames

 cleanup:
     sexpr_free(root);
-    return(ret);
+    return ret;

 error:
     for (i = 0; i < ret; ++i)
@@ -3581,7 +3581,7 @@ xenDaemonGetSchedulerParameters(virDomainPtr domain,

     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL)) {
         virXendError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return (-1);
+        return -1;
     }

     /* Support only xendConfigVersion >=4 */
@@ -3589,13 +3589,13 @@ xenDaemonGetSchedulerParameters(virDomainPtr domain,
     if (priv->xendConfigVersion < XEND_CONFIG_VERSION_3_1_0) {
         virXendError(VIR_ERR_OPERATION_INVALID,
                       "%s", _("unsupported in xendConfigVersion < 4"));
-        return (-1);
+        return -1;
     }

     /* look up the information by domain name */
     root = sexpr_get(domain->conn, "/xend/domain/%s?detail=1", domain->name);
     if (root == NULL)
-        return (-1);
+        return -1;

     /* get the scheduler type */
     sched_type = xenDaemonGetSchedulerType(domain, &sched_nparam);
@@ -3663,7 +3663,7 @@ xenDaemonGetSchedulerParameters(virDomainPtr domain,
 error:
     sexpr_free(root);
     VIR_FREE(sched_type);
-    return (ret);
+    return ret;
 }

 /**
@@ -3689,7 +3689,7 @@ xenDaemonSetSchedulerParameters(virDomainPtr domain,

     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL)) {
         virXendError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return (-1);
+        return -1;
     }

     /* Support only xendConfigVersion >=4 and active domains */
@@ -3697,13 +3697,13 @@ xenDaemonSetSchedulerParameters(virDomainPtr domain,
     if (priv->xendConfigVersion < XEND_CONFIG_VERSION_3_1_0) {
         virXendError(VIR_ERR_OPERATION_INVALID,
                       "%s", _("unsupported in xendConfigVersion < 4"));
-        return (-1);
+        return -1;
     }

     /* look up the information by domain name */
     root = sexpr_get(domain->conn, "/xend/domain/%s?detail=1", domain->name);
     if (root == NULL)
-        return (-1);
+        return -1;

     /* get the scheduler type */
     sched_type = xenDaemonGetSchedulerType(domain, &sched_nparam);
@@ -3773,7 +3773,7 @@ xenDaemonSetSchedulerParameters(virDomainPtr domain,
 error:
     sexpr_free(root);
     VIR_FREE(sched_type);
-    return (ret);
+    return ret;
 }

 /**
diff --git a/src/xen/xm_internal.c b/src/xen/xm_internal.c
index e966e63..09f05a0 100644
--- a/src/xen/xm_internal.c
+++ b/src/xen/xm_internal.c
@@ -140,9 +140,9 @@ static int xenXMConfigReaper(const void *payload, const void *key ATTRIBUTE_UNUS
         if (nameowner && STREQ(nameowner, key)) {
             virHashRemoveEntry(args->priv->nameConfigMap, olddomname);
         }
-        return (1);
+        return 1;
     }
-    return (0);
+    return 0;
 }


@@ -324,12 +324,12 @@ int xenXMConfigCacheRefresh (virConnectPtr conn) {
     if (now == ((time_t)-1)) {
         virReportSystemError(errno,
                              "%s", _("cannot get time of day"));
-        return (-1);
+        return -1;
     }

     /* Rate limit re-scans */
     if ((now - priv->lastRefresh) < XM_REFRESH_INTERVAL)
-        return (0);
+        return 0;

     priv->lastRefresh = now;

@@ -338,7 +338,7 @@ int xenXMConfigCacheRefresh (virConnectPtr conn) {
         virReportSystemError(errno,
                              _("cannot read directory %s"),
                              priv->configDir);
-        return (-1);
+        return -1;
     }

     while ((ent = readdir(dh))) {
@@ -404,7 +404,7 @@ int xenXMConfigCacheRefresh (virConnectPtr conn) {

     closedir(dh);

-    return (ret);
+    return ret;
 }


@@ -427,19 +427,19 @@ xenXMOpen (virConnectPtr conn,

     priv->configCache = virHashCreate(50, xenXMConfigFree);
     if (!priv->configCache)
-        return (-1);
+        return -1;
     priv->nameConfigMap = virHashCreate(50, NULL);
     if (!priv->nameConfigMap) {
         virHashFree(priv->configCache);
         priv->configCache = NULL;
-        return (-1);
+        return -1;
     }
     /* Force the cache to be reloaded next time that
      * xenXMConfigCacheRefresh is called.
      */
     priv->lastRefresh = 0;

-    return (0);
+    return 0;
 }

 /*
@@ -452,7 +452,7 @@ int xenXMClose(virConnectPtr conn) {
     virHashFree(priv->nameConfigMap);
     virHashFree(priv->configCache);

-    return (0);
+    return 0;
 }

 /*
@@ -487,11 +487,11 @@ int xenXMDomainGetInfo(virDomainPtr domain, virDomainInfoPtr info) {
     xenXMConfCachePtr entry;
     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL)) {
         xenXMError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(-1);
+        return -1;
     }

     if (domain->id != -1)
-        return (-1);
+        return -1;

     priv = domain->conn->privateData;
     xenUnifiedLock(priv);
@@ -510,7 +510,7 @@ int xenXMDomainGetInfo(virDomainPtr domain, virDomainInfoPtr info) {
     info->cpuTime = 0;

     xenUnifiedUnlock(priv);
-    return (0);
+    return 0;

 error:
     xenUnifiedUnlock(priv);
@@ -533,10 +533,10 @@ char *xenXMDomainGetXMLDesc(virDomainPtr domain, unsigned int flags)

     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL)) {
         xenXMError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(NULL);
+        return NULL;
     }
     if (domain->id != -1)
-        return (NULL);
+        return NULL;

     priv = domain->conn->privateData;
     xenUnifiedLock(priv);
@@ -566,14 +566,14 @@ int xenXMDomainSetMemory(virDomainPtr domain, unsigned long memory) {

     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL)) {
         xenXMError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return (-1);
+        return -1;
     }
     if (domain->conn->flags & VIR_CONNECT_RO)
-        return (-1);
+        return -1;
     if (domain->id != -1)
-        return (-1);
+        return -1;
     if (memory < 1024 * MIN_XEN_GUEST_SIZE)
-        return (-1);
+        return -1;

     priv = domain->conn->privateData;
     xenUnifiedLock(priv);
@@ -611,12 +611,12 @@ int xenXMDomainSetMaxMemory(virDomainPtr domain, unsigned long memory) {

     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL)) {
         xenXMError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return (-1);
+        return -1;
     }
     if (domain->conn->flags & VIR_CONNECT_RO)
-        return (-1);
+        return -1;
     if (domain->id != -1)
-        return (-1);
+        return -1;

     priv = domain->conn->privateData;
     xenUnifiedLock(priv);
@@ -654,10 +654,10 @@ unsigned long long xenXMDomainGetMaxMemory(virDomainPtr domain) {

     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL)) {
         xenXMError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return (0);
+        return 0;
     }
     if (domain->id != -1)
-        return (0);
+        return 0;

     priv = domain->conn->privateData;
     xenUnifiedLock(priv);
@@ -910,7 +910,7 @@ int xenXMDomainPinVcpu(virDomainPtr domain,
     VIR_FREE(mapsave);
     VIR_FREE(cpuset);
     xenUnifiedUnlock(priv);
-    return (ret);
+    return ret;
 }

 /*
@@ -924,11 +924,11 @@ virDomainPtr xenXMDomainLookupByName(virConnectPtr conn, const char *domname) {

     if (!VIR_IS_CONNECT(conn)) {
         xenXMError(VIR_ERR_INVALID_CONN, __FUNCTION__);
-        return (NULL);
+        return NULL;
     }
     if (domname == NULL) {
         xenXMError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return (NULL);
+        return NULL;
     }

     priv = conn->privateData;
@@ -952,7 +952,7 @@ virDomainPtr xenXMDomainLookupByName(virConnectPtr conn, const char *domname) {

 cleanup:
     xenUnifiedUnlock(priv);
-    return (ret);
+    return ret;
 }


@@ -964,9 +964,9 @@ static int xenXMDomainSearchForUUID(const void *payload, const void *name ATTRIB
     const xenXMConfCachePtr entry = (const xenXMConfCachePtr)payload;

     if (!memcmp(entry->def->uuid, wantuuid, VIR_UUID_BUFLEN))
-        return (1);
+        return 1;

-    return (0);
+    return 0;
 }

 /*
@@ -980,11 +980,11 @@ virDomainPtr xenXMDomainLookupByUUID(virConnectPtr conn,

     if (!VIR_IS_CONNECT(conn)) {
         xenXMError(VIR_ERR_INVALID_CONN, __FUNCTION__);
-        return (NULL);
+        return NULL;
     }
     if (uuid == NULL) {
         xenXMError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return (NULL);
+        return NULL;
     }

     priv = conn->privateData;
@@ -1005,7 +1005,7 @@ virDomainPtr xenXMDomainLookupByUUID(virConnectPtr conn,

 cleanup:
     xenUnifiedUnlock(priv);
-    return (ret);
+    return ret;
 }


@@ -1022,7 +1022,7 @@ int xenXMDomainCreate(virDomainPtr domain) {
     priv = (xenUnifiedPrivatePtr) domain->conn->privateData;

     if (domain->id != -1)
-        return (-1);
+        return -1;

     xenUnifiedLock(priv);

@@ -1052,7 +1052,7 @@ int xenXMDomainCreate(virDomainPtr domain) {
         goto error;

     xenUnifiedUnlock(priv);
-    return (0);
+    return 0;

  error:
     if (domain->id != -1) {
@@ -1060,7 +1060,7 @@ int xenXMDomainCreate(virDomainPtr domain) {
         domain->id = -1;
     }
     xenUnifiedUnlock(priv);
-    return (-1);
+    return -1;
 }

 /*
@@ -1079,27 +1079,27 @@ virDomainPtr xenXMDomainDefineXML(virConnectPtr conn, const char *xml)

     if (!VIR_IS_CONNECT(conn)) {
         xenXMError(VIR_ERR_INVALID_CONN, __FUNCTION__);
-        return (NULL);
+        return NULL;
     }
     if (xml == NULL) {
         xenXMError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return (NULL);
+        return NULL;
     }
     if (conn->flags & VIR_CONNECT_RO)
-        return (NULL);
+        return NULL;

     xenUnifiedLock(priv);

     if (!xenInotifyActive(conn) && xenXMConfigCacheRefresh (conn) < 0) {
         xenUnifiedUnlock(priv);
-        return (NULL);
+        return NULL;
     }

     if (!(def = virDomainDefParseString(priv->caps, xml,
                                         1 << VIR_DOMAIN_VIRT_XEN,
                                         VIR_DOMAIN_XML_INACTIVE))) {
         xenUnifiedUnlock(priv);
-        return (NULL);
+        return NULL;
     }

     if (!(conf = xenFormatXM(conn, def, priv->xendConfigVersion)))
@@ -1196,7 +1196,7 @@ virDomainPtr xenXMDomainDefineXML(virConnectPtr conn, const char *xml)
     ret = virGetDomain(conn, def->name, def->uuid);
     xenUnifiedUnlock(priv);
     VIR_FREE(filename);
-    return (ret);
+    return ret;

  error:
     VIR_FREE(filename);
@@ -1206,7 +1206,7 @@ virDomainPtr xenXMDomainDefineXML(virConnectPtr conn, const char *xml)
     virConfFree(conf);
     virDomainDefFree(def);
     xenUnifiedUnlock(priv);
-    return (NULL);
+    return NULL;
 }

 /*
@@ -1220,13 +1220,13 @@ int xenXMDomainUndefine(virDomainPtr domain) {

     if ((domain == NULL) || (domain->conn == NULL) || (domain->name == NULL)) {
         xenXMError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return (-1);
+        return -1;
     }

     if (domain->id != -1)
-        return (-1);
+        return -1;
     if (domain->conn->flags & VIR_CONNECT_RO)
-        return (-1);
+        return -1;

     priv = domain->conn->privateData;
     xenUnifiedLock(priv);
@@ -1296,7 +1296,7 @@ int xenXMListDefinedDomains(virConnectPtr conn, char **const names, int maxnames

     if (!VIR_IS_CONNECT(conn)) {
         xenXMError(VIR_ERR_INVALID_CONN, __FUNCTION__);
-        return (-1);
+        return -1;
     }

     priv = conn->privateData;
@@ -1341,7 +1341,7 @@ int xenXMNumOfDefinedDomains(virConnectPtr conn) {

     if (!VIR_IS_CONNECT(conn)) {
         xenXMError(VIR_ERR_INVALID_CONN, __FUNCTION__);
-        return (-1);
+        return -1;
     }

     priv = conn->privateData;
@@ -1566,7 +1566,7 @@ xenXMDomainDetachDeviceFlags(virDomainPtr domain, const char *xml,
  cleanup:
     virDomainDeviceDefFree(dev);
     xenUnifiedUnlock(priv);
-    return (ret);
+    return ret;
 }

 int
diff --git a/src/xen/xs_internal.c b/src/xen/xs_internal.c
index 729873f..d1bcb27 100644
--- a/src/xen/xs_internal.c
+++ b/src/xen/xs_internal.c
@@ -81,7 +81,7 @@ virConnectDoStoreList(virConnectPtr conn, const char *path,

     priv = (xenUnifiedPrivatePtr) conn->privateData;
     if (priv->xshandle == NULL || path == NULL || nb == NULL)
-        return (NULL);
+        return NULL;

     return xs_directory (priv->xshandle, 0, path, nb);
 }
@@ -108,7 +108,7 @@ virDomainDoStoreQuery(virConnectPtr conn, int domid, const char *path)

     priv = (xenUnifiedPrivatePtr) conn->privateData;
     if (priv->xshandle == NULL)
-        return (NULL);
+        return NULL;

     snprintf(s, 255, "/local/domain/%d/%s", domid, path);
     s[255] = 0;
@@ -135,13 +135,13 @@ virDomainDoStoreWrite(virDomainPtr domain, const char *path,
     int ret = -1;

     if (!VIR_IS_CONNECTED_DOMAIN(domain))
-        return (-1);
+        return -1;

     priv = (xenUnifiedPrivatePtr) domain->conn->privateData;
     if (priv->xshandle == NULL)
-        return (-1);
+        return -1;
     if (domain->conn->flags & VIR_CONNECT_RO)
-        return (-1);
+        return -1;

     snprintf(s, 255, "/local/domain/%d/%s", domain->id, path);
     s[255] = 0;
@@ -149,7 +149,7 @@ virDomainDoStoreWrite(virDomainPtr domain, const char *path,
     if (xs_write(priv->xshandle, 0, &s[0], value, strlen(value)))
         ret = 0;

-    return (ret);
+    return ret;
 }

 /**
@@ -169,18 +169,18 @@ virDomainGetVM(virDomainPtr domain)
     xenUnifiedPrivatePtr priv;

     if (!VIR_IS_CONNECTED_DOMAIN(domain))
-        return (NULL);
+        return NULL;

     priv = (xenUnifiedPrivatePtr) domain->conn->privateData;
     if (priv->xshandle == NULL)
-        return (NULL);
+        return NULL;

     snprintf(query, 199, "/local/domain/%d/vm", virDomainGetID(domain));
     query[199] = 0;

     vm = xs_read(priv->xshandle, 0, &query[0], &len);

-    return (vm);
+    return vm;
 }

 /**
@@ -203,18 +203,18 @@ virDomainGetVMInfo(virDomainPtr domain, const char *vm, const char *name)
     xenUnifiedPrivatePtr priv;

     if (!VIR_IS_CONNECTED_DOMAIN(domain))
-        return (NULL);
+        return NULL;

     priv = (xenUnifiedPrivatePtr) domain->conn->privateData;
     if (priv->xshandle == NULL)
-        return (NULL);
+        return NULL;

     snprintf(s, 255, "%s/%s", vm, name);
     s[255] = 0;

     ret = xs_read(priv->xshandle, 0, &s[0], &len);

-    return (ret);
+    return ret;
 }


@@ -257,7 +257,7 @@ xenStoreOpen(virConnectPtr conn,
             virXenStoreError(VIR_ERR_NO_XEN,
                              "%s", _("failed to connect to Xen Store"));
         }
-        return (-1);
+        return -1;
     }

     /* Init activeDomainList */
@@ -318,7 +318,7 @@ xenStoreClose(virConnectPtr conn)

     if (conn == NULL) {
         virXenStoreError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(-1);
+        return -1;
     }

     priv = (xenUnifiedPrivatePtr) conn->privateData;
@@ -339,7 +339,7 @@ xenStoreClose(virConnectPtr conn)
     priv->activeDomainList = NULL;

     if (priv->xshandle == NULL)
-        return(-1);
+        return -1;

     if (priv->xsWatch != -1)
         virEventRemoveHandle(priv->xsWatch);
@@ -347,7 +347,7 @@ xenStoreClose(virConnectPtr conn)
     xs_daemon_close(priv->xshandle);
     priv->xshandle = NULL;

-    return (0);
+    return 0;
 }

 /**
@@ -368,19 +368,19 @@ xenStoreGetDomainInfo(virDomainPtr domain, virDomainInfoPtr info)
     xenUnifiedPrivatePtr priv;

     if (!VIR_IS_CONNECTED_DOMAIN(domain))
-        return (-1);
+        return -1;

     if ((domain == NULL) || (domain->conn == NULL) || (info == NULL)) {
         virXenStoreError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(-1);
+        return -1;
     }

     priv = (xenUnifiedPrivatePtr) domain->conn->privateData;
     if (priv->xshandle == NULL)
-        return(-1);
+        return -1;

     if (domain->id == -1)
-        return(-1);
+        return -1;

     tmp = virDomainDoStoreQuery(domain->conn, domain->id, "running");
     if (tmp != NULL) {
@@ -416,7 +416,7 @@ xenStoreGetDomainInfo(virDomainPtr domain, virDomainInfoPtr info)
         info->nrVirtCpu = nb_vcpus;
         VIR_FREE(tmp2);
     }
-    return (0);
+    return 0;
 }

 /**
@@ -473,18 +473,18 @@ xenStoreDomainSetMemory(virDomainPtr domain, unsigned long memory)
     if ((domain == NULL) || (domain->conn == NULL) ||
         (memory < 1024 * MIN_XEN_GUEST_SIZE)) {
         virXenStoreError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(-1);
+        return -1;
     }
     if (domain->id == -1)
-        return(-1);
+        return -1;
     if ((domain->id == 0) && (memory < (2 * MIN_XEN_GUEST_SIZE * 1024)))
-        return(-1);
+        return -1;
     snprintf(value, 19, "%lu", memory);
     value[19] = 0;
     ret = virDomainDoStoreWrite(domain, "memory/target", &value[0]);
     if (ret < 0)
-        return (-1);
-    return (0);
+        return -1;
+    return 0;
 }

 /**
@@ -503,7 +503,7 @@ xenStoreDomainGetMaxMemory(virDomainPtr domain)
     xenUnifiedPrivatePtr priv;

     if (!VIR_IS_CONNECTED_DOMAIN(domain))
-        return (ret);
+        return ret;
     if (domain->id == -1)
         return 0;

@@ -515,7 +515,7 @@ xenStoreDomainGetMaxMemory(virDomainPtr domain)
         VIR_FREE(tmp);
     }
     xenUnifiedUnlock(priv);
-    return(ret);
+    return ret;
 }

 /**
@@ -543,7 +543,7 @@ xenStoreNumOfDomains(virConnectPtr conn)
     priv = (xenUnifiedPrivatePtr) conn->privateData;
     if (priv->xshandle == NULL) {
         virXenStoreError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(-1);
+        return -1;
     }

     idlist = xs_directory(priv->xshandle, 0, "/local/domain", &num);
@@ -562,7 +562,7 @@ out:
         VIR_FREE (idlist);
         ret = realnum;
     }
-    return(ret);
+    return ret;
 }

 /**
@@ -625,7 +625,7 @@ xenStoreListDomains(virConnectPtr conn, int *ids, int maxids)

     if ((conn == NULL) || (ids == NULL)) {
         virXenStoreError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(-1);
+        return -1;
     }

     priv = (xenUnifiedPrivatePtr) conn->privateData;
@@ -634,7 +634,7 @@ xenStoreListDomains(virConnectPtr conn, int *ids, int maxids)
     ret = xenStoreDoListDomains(conn, priv, ids, maxids);
     xenUnifiedUnlock(priv);

-    return(ret);
+    return ret;
 }

 /**
@@ -660,12 +660,12 @@ xenStoreLookupByName(virConnectPtr conn, const char *name)

     if ((conn == NULL) || (name == NULL)) {
         virXenStoreError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(NULL);
+        return NULL;
     }

     priv = (xenUnifiedPrivatePtr) conn->privateData;
     if (priv->xshandle == NULL)
-        return(NULL);
+        return NULL;

     idlist = xs_directory(priv->xshandle, 0, "/local/domain", &num);
     if (idlist == NULL)
@@ -703,7 +703,7 @@ done:
     VIR_FREE(xenddomain);
     VIR_FREE(idlist);

-    return(ret);
+    return ret;
 }

 /**
@@ -724,10 +724,10 @@ xenStoreDomainShutdown(virDomainPtr domain)

     if ((domain == NULL) || (domain->conn == NULL)) {
         virXenStoreError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(-1);
+        return -1;
     }
     if (domain->id == -1 || domain->id == 0)
-        return(-1);
+        return -1;
     /*
      * this is very hackish, the domU kernel probes for a special
      * node in the xenstore and launch the shutdown command if found.
@@ -760,10 +760,10 @@ xenStoreDomainReboot(virDomainPtr domain, unsigned int flags)

     if ((domain == NULL) || (domain->conn == NULL)) {
         virXenStoreError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(-1);
+        return -1;
     }
     if (domain->id == -1 || domain->id == 0)
-        return(-1);
+        return -1;
     /*
      * this is very hackish, the domU kernel probes for a special
      * node in the xenstore and launch the shutdown command if found.
@@ -790,7 +790,7 @@ xenStoreDomainGetOSType(virDomainPtr domain) {

     if ((domain == NULL) || (domain->conn == NULL)) {
         virXenStoreError(VIR_ERR_INVALID_ARG, __FUNCTION__);
-        return(NULL);
+        return NULL;
     }

     vm = virDomainGetVM(domain);
@@ -802,7 +802,7 @@ xenStoreDomainGetOSType(virDomainPtr domain) {
         VIR_FREE(vm);
     }

-    return (str);
+    return str;
 }

 /**
@@ -830,7 +830,7 @@ int             xenStoreDomainGetVNCPort(virConnectPtr conn, int domid) {
             ret = -1;
         VIR_FREE(tmp);
     }
-    return(ret);
+    return ret;
 }

 /**
@@ -895,18 +895,18 @@ xenStoreDomainGetNetworkID(virConnectPtr conn, int id, const char *mac) {
     xenUnifiedPrivatePtr priv;

     if (id < 0)
-        return(NULL);
+        return NULL;

     priv = (xenUnifiedPrivatePtr) conn->privateData;
     if (priv->xshandle == NULL)
-        return (NULL);
+        return NULL;
     if (mac == NULL)
-        return (NULL);
+        return NULL;

     snprintf(dir, sizeof(dir), "/local/domain/0/backend/vif/%d", id);
     list = xs_directory(priv->xshandle, 0, dir, &num);
     if (list == NULL)
-        return(NULL);
+        return NULL;
     for (i = 0; i < num; i++) {
         snprintf(path, sizeof(path), "%s/%s/%s", dir, list[i], "mac");
         if ((val = xs_read(priv->xshandle, 0, path, &len)) == NULL)
@@ -927,7 +927,7 @@ xenStoreDomainGetNetworkID(virConnectPtr conn, int id, const char *mac) {
     }

     VIR_FREE(list);
-    return(ret);
+    return ret;
 }

 /*
@@ -953,16 +953,16 @@ xenStoreDomainGetDiskID(virConnectPtr conn, int id, const char *dev) {
     xenUnifiedPrivatePtr priv;

     if (id < 0)
-        return(NULL);
+        return NULL;

     priv = (xenUnifiedPrivatePtr) conn->privateData;
     if (priv->xshandle == NULL)
-        return (NULL);
+        return NULL;
     if (dev == NULL)
-        return (NULL);
+        return NULL;
     devlen = strlen(dev);
     if (devlen <= 0)
-        return (NULL);
+        return NULL;

     snprintf(dir, sizeof(dir), "/local/domain/0/backend/vbd/%d", id);
     list = xs_directory(priv->xshandle, 0, dir, &num);
@@ -982,7 +982,7 @@ xenStoreDomainGetDiskID(virConnectPtr conn, int id, const char *dev) {

                 VIR_FREE (val);
                 VIR_FREE (list);
-                return (ret);
+                return ret;
             }
         }
         VIR_FREE (list);
@@ -1005,12 +1005,12 @@ xenStoreDomainGetDiskID(virConnectPtr conn, int id, const char *dev) {

                 VIR_FREE (val);
                 VIR_FREE (list);
-                return (ret);
+                return ret;
             }
         }
         VIR_FREE (list);
     }
-    return (NULL);
+    return NULL;
 }

 /*
@@ -1037,18 +1037,18 @@ xenStoreDomainGetPCIID(virConnectPtr conn, int id, const char *bdf)
     xenUnifiedPrivatePtr priv;

     if (id < 0)
-        return(NULL);
+        return NULL;

     priv = (xenUnifiedPrivatePtr) conn->privateData;
     if (priv->xshandle == NULL)
-        return (NULL);
+        return NULL;
     if (bdf == NULL)
-        return (NULL);
+        return NULL;

     snprintf(dir, sizeof(dir), "/local/domain/0/backend/pci/%d", id);
     list = xs_directory(priv->xshandle, 0, dir, &num);
     if (list == NULL)
-        return(NULL);
+        return NULL;
     for (i = 0; i < num; i++) {
         snprintf(path, sizeof(path), "%s/%s/%s", dir, list[i], "dev-0");
         if ((val = xs_read(priv->xshandle, 0, path, &len)) == NULL)
@@ -1065,7 +1065,7 @@ xenStoreDomainGetPCIID(virConnectPtr conn, int id, const char *bdf)
     }

     VIR_FREE(list);
-    return(ret);
+    return ret;
 }

 /*
@@ -1080,7 +1080,7 @@ char *xenStoreDomainGetName(virConnectPtr conn,

     priv = (xenUnifiedPrivatePtr) conn->privateData;
     if (priv->xshandle == NULL)
-        return(NULL);
+        return NULL;

     snprintf(prop, 199, "/local/domain/%d/name", id);
     prop[199] = 0;
diff --git a/src/xenapi/xenapi_driver.c b/src/xenapi/xenapi_driver.c
index 298db12..d29f8e1 100644
--- a/src/xenapi/xenapi_driver.c
+++ b/src/xenapi/xenapi_driver.c
@@ -972,7 +972,7 @@ xenapiDomainGetMaxMemory (virDomainPtr dom)
         vm = vms->contents[0];
         xen_vm_get_memory_static_max(session, &mem_static_max, vm);
         xen_vm_set_free(vms);
-        return (mem_static_max / 1024);
+        return mem_static_max / 1024;
     } else {
         if (vms) xen_vm_set_free(vms);
         xenapiSessionErrorHandler(dom->conn, VIR_ERR_NO_DOMAIN, NULL);
diff --git a/src/xenxs/xen_sxpr.c b/src/xenxs/xen_sxpr.c
index 6d76ffe..d16be18 100644
--- a/src/xenxs/xen_sxpr.c
+++ b/src/xenxs/xen_sxpr.c
@@ -95,7 +95,7 @@ xenParseSxprOS(const struct sexpr *node,
             if (def->os.loader == NULL) {
                 XENXS_ERROR(VIR_ERR_INTERNAL_ERROR,
                              "%s", _("domain information incomplete, missing HVM loader"));
-                return(-1);
+                return -1;
             }
         } else {
             if (sexpr_node_copy(node, "domain/image/hvm/kernel", &def->os.kernel) < 0)
diff --git a/src/xenxs/xen_xm.c b/src/xenxs/xen_xm.c
index 7e7921b..31d8858 100644
--- a/src/xenxs/xen_xm.c
+++ b/src/xenxs/xen_xm.c
@@ -1951,5 +1951,5 @@ cleanup:
     VIR_FREE(cpus);
     if (conf)
         virConfFree(conf);
-    return (NULL);
+    return NULL;
 }
diff --git a/tests/commandtest.c b/tests/commandtest.c
index 3997d2c..28dc875 100644
--- a/tests/commandtest.c
+++ b/tests/commandtest.c
@@ -803,7 +803,7 @@ mymain(void)
     int fd;

     if (chdir("/tmp") < 0)
-        return(EXIT_FAILURE);
+        return EXIT_FAILURE;

     setpgid(0, 0);
     setsid();
@@ -868,7 +868,7 @@ mymain(void)
     DO_TEST(test18);
     DO_TEST(test19);

-    return(ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret==0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tests/cputest.c b/tests/cputest.c
index 870f99f..6c1efe6 100644
--- a/tests/cputest.c
+++ b/tests/cputest.c
@@ -632,7 +632,7 @@ mymain(void)
                       models, "Penryn", -1);

     VIR_FREE(map);
-    return (ret == 0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret == 0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tests/domainsnapshotxml2xmltest.c b/tests/domainsnapshotxml2xmltest.c
index 978a2d4..e363c99 100644
--- a/tests/domainsnapshotxml2xmltest.c
+++ b/tests/domainsnapshotxml2xmltest.c
@@ -88,7 +88,7 @@ mymain(void)
     int ret = 0;

     if ((driver.caps = testQemuCapsInit()) == NULL)
-        return (EXIT_FAILURE);
+        return EXIT_FAILURE;

 # define DO_TEST(name, uuid, internal)                                  \
     do {                                                                \
@@ -113,7 +113,7 @@ mymain(void)

     virCapabilitiesFree(driver.caps);

-    return (ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret==0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tests/interfacexml2xmltest.c b/tests/interfacexml2xmltest.c
index c5c5415..f969fa1 100644
--- a/tests/interfacexml2xmltest.c
+++ b/tests/interfacexml2xmltest.c
@@ -92,7 +92,7 @@ mymain(void)
     DO_TEST("ipv6-static-multi");
     DO_TEST("ipv6-static");

-    return (ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret==0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tests/networkxml2argvtest.c b/tests/networkxml2argvtest.c
index e000be9..cf00181 100644
--- a/tests/networkxml2argvtest.c
+++ b/tests/networkxml2argvtest.c
@@ -157,7 +157,7 @@ mymain(void)
     DO_TEST("nat-network-dns-srv-record-minimal");
     DO_TEST("nat-network-dns-hosts");

-    return (ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret==0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tests/networkxml2xmltest.c b/tests/networkxml2xmltest.c
index 77528a8..8641c41 100644
--- a/tests/networkxml2xmltest.c
+++ b/tests/networkxml2xmltest.c
@@ -106,7 +106,7 @@ mymain(void)
     DO_TEST("bandwidth-network");
     DO_TEST_FULL("passthrough-pf", VIR_NETWORK_XML_INACTIVE);

-    return (ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret==0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tests/nodedevxml2xmltest.c b/tests/nodedevxml2xmltest.c
index c002ead..38f2e9a 100644
--- a/tests/nodedevxml2xmltest.c
+++ b/tests/nodedevxml2xmltest.c
@@ -85,7 +85,7 @@ mymain(void)
     DO_TEST("usb_device_1d6b_1_0000_00_1d_0_if0");
     DO_TEST("usb_device_1d6b_1_0000_00_1d_0");

-    return (ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret==0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tests/nodeinfotest.c b/tests/nodeinfotest.c
index 32d964e..74bf811 100644
--- a/tests/nodeinfotest.c
+++ b/tests/nodeinfotest.c
@@ -141,7 +141,7 @@ mymain(void)
       if (virtTestRun(nodeData[i], 1, linuxTestNodeInfo, nodeData[i]) != 0)
         ret = -1;

-    return(ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret==0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tests/nwfilterxml2xmltest.c b/tests/nwfilterxml2xmltest.c
index db7fe78..5fd8df8 100644
--- a/tests/nwfilterxml2xmltest.c
+++ b/tests/nwfilterxml2xmltest.c
@@ -157,7 +157,7 @@ mymain(void)
     DO_TEST("iter-test2", false);
     DO_TEST("iter-test3", false);

-    return (ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret==0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tests/qemuargv2xmltest.c b/tests/qemuargv2xmltest.c
index e13b87a..439218e 100644
--- a/tests/qemuargv2xmltest.c
+++ b/tests/qemuargv2xmltest.c
@@ -242,7 +242,7 @@ mymain(void)
     VIR_FREE(driver.stateDir);
     virCapabilitiesFree(driver.caps);

-    return(ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret==0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tests/qemuxml2argvtest.c b/tests/qemuxml2argvtest.c
index d0affc7..fc6786a 100644
--- a/tests/qemuxml2argvtest.c
+++ b/tests/qemuxml2argvtest.c
@@ -754,7 +754,7 @@ mymain(void)
     virCapabilitiesFree(driver.caps);
     VIR_FREE(map);

-    return(ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret==0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tests/qemuxml2xmltest.c b/tests/qemuxml2xmltest.c
index 3f749d2..42e4d9d 100644
--- a/tests/qemuxml2xmltest.c
+++ b/tests/qemuxml2xmltest.c
@@ -100,7 +100,7 @@ mymain(void)
     int ret = 0;

     if ((driver.caps = testQemuCapsInit()) == NULL)
-        return (EXIT_FAILURE);
+        return EXIT_FAILURE;

 # define DO_TEST_FULL(name, is_different, inactive)                     \
     do {                                                                \
@@ -227,7 +227,7 @@ mymain(void)

     virCapabilitiesFree(driver.caps);

-    return (ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret==0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tests/qemuxmlnstest.c b/tests/qemuxmlnstest.c
index 6ae5880..8eca466 100644
--- a/tests/qemuxmlnstest.c
+++ b/tests/qemuxmlnstest.c
@@ -280,7 +280,7 @@ mymain(void)
     virCapabilitiesFree(driver.caps);
     VIR_FREE(map);

-    return(ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret==0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tests/qparamtest.c b/tests/qparamtest.c
index 78551c6..becf22a 100644
--- a/tests/qparamtest.c
+++ b/tests/qparamtest.c
@@ -222,7 +222,7 @@ mymain(void)
     if (virtTestRun("Add vargs", 1, qparamTestAddVargs, NULL) < 0)
         ret = -1;

-    return(ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret==0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tests/sexpr2xmltest.c b/tests/sexpr2xmltest.c
index 12d9086..57379b7 100644
--- a/tests/sexpr2xmltest.c
+++ b/tests/sexpr2xmltest.c
@@ -113,7 +113,7 @@ mymain(void)
     int ret = 0;

     if (!(caps = testXenCapsInit()))
-        return(EXIT_FAILURE);
+        return EXIT_FAILURE;

 #define DO_TEST(in, out, version)                                      \
     do {                                                               \
@@ -186,7 +186,7 @@ mymain(void)

     virCapabilitiesFree(caps);

-    return(ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret==0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tests/sockettest.c b/tests/sockettest.c
index bcc2800..777da4a 100644
--- a/tests/sockettest.c
+++ b/tests/sockettest.c
@@ -252,7 +252,7 @@ mymain(void)
     DO_TEST_NETMASK("2000::1:1", "9000::1:1",
                     "ffff:ffff:ffff:ffff:ffff:ffff:ffff:0", false);

-    return(ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret==0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tests/statstest.c b/tests/statstest.c
index fff69a3..8c40082 100644
--- a/tests/statstest.c
+++ b/tests/statstest.c
@@ -213,7 +213,7 @@ mymain(void)
     DO_TEST("/dev/xvda1", 51713);
     DO_TEST("/dev/xvda15", 51727);

-    return(ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret==0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tests/storagepoolxml2xmltest.c b/tests/storagepoolxml2xmltest.c
index 886f310..d73fc8a 100644
--- a/tests/storagepoolxml2xmltest.c
+++ b/tests/storagepoolxml2xmltest.c
@@ -94,7 +94,7 @@ mymain(void)
     DO_TEST("pool-iscsi-multiiqn");
     DO_TEST("pool-iscsi-vendor-product");

-    return (ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret==0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tests/storagevolxml2xmltest.c b/tests/storagevolxml2xmltest.c
index 742a02c..37c92cd 100644
--- a/tests/storagevolxml2xmltest.c
+++ b/tests/storagevolxml2xmltest.c
@@ -113,7 +113,7 @@ mymain(void)
     DO_TEST("pool-logical", "vol-logical");
     DO_TEST("pool-logical", "vol-logical-backing");

-    return (ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret==0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tests/virbuftest.c b/tests/virbuftest.c
index 51a62fe..9058920 100644
--- a/tests/virbuftest.c
+++ b/tests/virbuftest.c
@@ -150,7 +150,7 @@ mymain(void)
     DO_TEST("VSprintf infinite loop", testBufInfiniteLoop, 0);
     DO_TEST("Auto-indentation", testBufAutoIndent, 0);

-    return(ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret==0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tests/virnetmessagetest.c b/tests/virnetmessagetest.c
index a378ed5..28dc09f 100644
--- a/tests/virnetmessagetest.c
+++ b/tests/virnetmessagetest.c
@@ -506,7 +506,7 @@ mymain(void)
     if (virtTestRun("Message Payload Stream Encode", 1, testMessagePayloadStreamEncode, NULL) < 0)
         ret = -1;

-    return (ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret==0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tests/virnetsockettest.c b/tests/virnetsockettest.c
index 44d6f65..f0d1968 100644
--- a/tests/virnetsockettest.c
+++ b/tests/virnetsockettest.c
@@ -460,7 +460,7 @@ mymain(void)
 #ifdef HAVE_IFADDRS_H
     if (checkProtocols(&hasIPv4, &hasIPv6, &freePort) < 0) {
         fprintf(stderr, "Cannot identify IPv4/6 availability\n");
-        return (EXIT_FAILURE);
+        return EXIT_FAILURE;
     }

     if (hasIPv4) {
@@ -602,7 +602,7 @@ mymain(void)

 #endif

-    return (ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret==0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tests/virnettlscontexttest.c b/tests/virnettlscontexttest.c
index 898e3ab..8e805d8 100644
--- a/tests/virnettlscontexttest.c
+++ b/tests/virnettlscontexttest.c
@@ -1245,7 +1245,7 @@ mymain(void)

     asn1_delete_structure(&pkix_asn1);

-    return (ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret==0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tests/virshtest.c b/tests/virshtest.c
index 87b1336..2a89866 100644
--- a/tests/virshtest.c
+++ b/tests/virshtest.c
@@ -395,7 +395,7 @@ mymain(void)
 # undef DO_TEST

     VIR_FREE(custom_uri);
-    return(ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret==0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tests/virtimetest.c b/tests/virtimetest.c
index 5d56dd3..ac06e89 100644
--- a/tests/virtimetest.c
+++ b/tests/virtimetest.c
@@ -118,7 +118,7 @@ mymain(void)

     TEST_FIELDS(2147483648000ull, 2038,  1, 19,  3, 14,  8);

-    return (ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret==0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tests/xencapstest.c b/tests/xencapstest.c
index 321f38a..387e278 100644
--- a/tests/xencapstest.c
+++ b/tests/xencapstest.c
@@ -210,7 +210,7 @@ mymain(void)
         ret = -1;


-    return(ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret==0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tests/xmconfigtest.c b/tests/xmconfigtest.c
index f1e028a..9956bf2 100644
--- a/tests/xmconfigtest.c
+++ b/tests/xmconfigtest.c
@@ -192,7 +192,7 @@ mymain(void)
     int ret = 0;

     if (!(caps = testXenCapsInit()))
-        return(EXIT_FAILURE);
+        return EXIT_FAILURE;

 #define DO_TEST(name, version)                                          \
     do {                                                                \
@@ -247,7 +247,7 @@ mymain(void)

     virCapabilitiesFree(caps);

-    return(ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret==0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tests/xml2sexprtest.c b/tests/xml2sexprtest.c
index 12d63b6..0a17c81 100644
--- a/tests/xml2sexprtest.c
+++ b/tests/xml2sexprtest.c
@@ -100,7 +100,7 @@ mymain(void)
     } while (0)

     if (!(caps = testXenCapsInit()))
-        return(EXIT_FAILURE);
+        return EXIT_FAILURE;

     DO_TEST("pv", "pv", "pvtest", 1);
     DO_TEST("fv", "fv", "fvtest", 1);
@@ -170,7 +170,7 @@ mymain(void)

     virCapabilitiesFree(caps);

-    return(ret==0 ? EXIT_SUCCESS : EXIT_FAILURE);
+    return ret==0 ? EXIT_SUCCESS : EXIT_FAILURE;
 }

 VIRT_TEST_MAIN(mymain)
diff --git a/tools/virsh.c b/tools/virsh.c
index 9e5c9b2..75594a5 100644
--- a/tools/virsh.c
+++ b/tools/virsh.c
@@ -471,7 +471,7 @@ _vshStrdup(vshControl *ctl, const char *s, const char *filename, int line)
     char *x;

     if (s == NULL)
-        return(NULL);
+        return NULL;
     if ((x = strdup(s)))
         return x;
     vshError(ctl, _("%s: %d: failed to allocate %lu bytes"),
@@ -518,13 +518,13 @@ prettyCapacity(unsigned long long val,
         return (((double)val / 1024.0l));
     } else if (val < (1024.0l * 1024.0l * 1024.0l)) {
         *unit = "MB";
-        return ((double)val / (1024.0l * 1024.0l));
+        return (double)val / (1024.0l * 1024.0l);
     } else if (val < (1024.0l * 1024.0l * 1024.0l * 1024.0l)) {
         *unit = "GB";
-        return ((double)val / (1024.0l * 1024.0l * 1024.0l));
+        return (double)val / (1024.0l * 1024.0l * 1024.0l);
     } else {
         *unit = "TB";
-        return ((double)val / (1024.0l * 1024.0l * 1024.0l * 1024.0l));
+        return (double)val / (1024.0l * 1024.0l * 1024.0l * 1024.0l);
     }
 }

-- 
1.7.3.4

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list


[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]