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

[Xen-changelog] [xen master] xmalloc: correct _xmalloc_array() indentation



commit bb8597b6d36d66a1972c62beb2300fcdeff1747f
Author:     Jan Beulich <jbeulich@xxxxxxxx>
AuthorDate: Fri May 19 10:10:49 2017 +0200
Commit:     Jan Beulich <jbeulich@xxxxxxxx>
CommitDate: Fri May 19 10:10:49 2017 +0200

    xmalloc: correct _xmalloc_array() indentation
    
    It's been wrongly indented using tabs till now, and the stray blank
    ahead of the final return statement gets in the way of using .i files
    for detailed analysis of other compiler issues
    (-Wmisleading-indentation kicks in due to the tab->space
    transformation done in the course of pre-processing).
    
    Also add missing spaces inside the if() at once, including the similar
    case in _xzalloc_array().
    
    Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx>
    Reviewed-by: Wei Liu <wei.liu2@xxxxxxxxxx>
    Reviewed-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
    Release-acked-by: Julien Grall <julien.grall@xxxxxxx>
---
 xen/include/xen/xmalloc.h | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/xen/include/xen/xmalloc.h b/xen/include/xen/xmalloc.h
index 24a99ac..cc2673d 100644
--- a/xen/include/xen/xmalloc.h
+++ b/xen/include/xen/xmalloc.h
@@ -33,17 +33,17 @@ extern void *_xzalloc(unsigned long size, unsigned long 
align);
 static inline void *_xmalloc_array(
     unsigned long size, unsigned long align, unsigned long num)
 {
-       /* Check for overflow. */
-       if (size && num > UINT_MAX / size)
-               return NULL;
-       return _xmalloc(size * num, align);
+    /* Check for overflow. */
+    if ( size && num > UINT_MAX / size )
+        return NULL;
+    return _xmalloc(size * num, align);
 }
 
 static inline void *_xzalloc_array(
     unsigned long size, unsigned long align, unsigned long num)
 {
     /* Check for overflow. */
-    if (size && num > UINT_MAX / size)
+    if ( size && num > UINT_MAX / size )
         return NULL;
     return _xzalloc(size * num, align);
 }
--
generated by git-patchbot for /home/xen/git/xen.git#master

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxx
https://lists.xenproject.org/xen-changelog

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.