From: Wilhansen Li Date: Mon, 26 Dec 2016 17:30:36 +0000 (+0800) Subject: Fix formatting. X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=56599acb730dfd061ebeb32cdd17a7b46cdd80ba;p=GitHub%2FLineageOS%2FG12%2Fandroid_hardware_amlogic_tools_dtbtool.git Fix formatting. --- diff --git a/dtbTool.c b/dtbTool.c index b5dd935..9b28396 100644 --- a/dtbTool.c +++ b/dtbTool.c @@ -84,15 +84,18 @@ int entry_cmp(uint8_t *a, uint8_t *b) return memcmp(a, b, INFO_ENTRY_SIZE); } -uint32_t swap_bytes_u32(uint32_t b) { +uint32_t swap_bytes_u32(uint32_t b) +{ return ((b & 0xFF000000) >> 24) | ((b & 0x00FF0000) >> 8) | ((b & 0x0000FF00) << 8) | (b << 24); } -void padSpaces(uint8_t *s, int sz) { +void padSpaces(uint8_t *s, int sz) +{ --sz; - while ( sz >= 0 && s[sz] == 0 ) { + while ( sz >= 0 && s[sz] == 0 ) + { s[sz] = 0x20; --sz; }