summaryrefslogtreecommitdiff
path: root/lib/cvtoct.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/cvtoct.c')
-rw-r--r--lib/cvtoct.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/lib/cvtoct.c b/lib/cvtoct.c
index dafd8ff..0e03cad 100644
--- a/lib/cvtoct.c
+++ b/lib/cvtoct.c
@@ -27,23 +27,23 @@
**
** NOTE: assumes buf is large enough to hold the resulting string
*/
-int cvtoct( char *buf, uint32_t value ) {
+int cvtoct(char *buf, uint32_t value)
+{
int i;
int chars_stored = 0;
char *bp = buf;
uint32_t val;
- val = ( value & 0xc0000000 );
+ val = (value & 0xc0000000);
val >>= 30;
- for( i = 0; i < 11; i += 1 ){
-
- if( i == 10 || val != 0 || chars_stored ) {
+ for (i = 0; i < 11; i += 1) {
+ if (i == 10 || val != 0 || chars_stored) {
chars_stored = 1;
val &= 0x7;
*bp++ = val + '0';
}
value <<= 3;
- val = ( value & 0xe0000000 );
+ val = (value & 0xe0000000);
val >>= 29;
}
*bp = '\0';