Fossil SCM
More coding style fixes.
Commit
2dca9b82d943d36caa1cc95060dbf1f892bc01f8
Parent
aadbbb38d6cd3e7…
1 file changed
+4
-5
+4
-5
| --- src/comformat.c | ||
| +++ src/comformat.c | ||
| @@ -232,11 +232,11 @@ | ||
| 232 | 232 | #endif |
| 233 | 233 | if( indent>sizeof(zBuf)-6 ) /* Limit initial indent to fit output buffer. */ |
| 234 | 234 | indent = sizeof(zBuf)-6; |
| 235 | 235 | comment_calc_indent(zLine, indent, trimCrLf, trimSpace, &index); |
| 236 | 236 | if( indent>0 ){ |
| 237 | - for ( i=0; i<indent; i++ ){ | |
| 237 | + for( i=0; i<indent; i++ ){ | |
| 238 | 238 | zBuf[iBuf++] = ' '; |
| 239 | 239 | } |
| 240 | 240 | } |
| 241 | 241 | if( origIndent>sizeof(zBuf)-6 ) /* Limit line indent to fit output buffer. */ |
| 242 | 242 | origIndent = sizeof(zBuf)-6; |
| @@ -259,11 +259,11 @@ | ||
| 259 | 259 | const char *zCurrent = &zLine[index]; |
| 260 | 260 | if( comment_check_orig(zOrigText, zCurrent, &charCnt, &lineCnt) ){ |
| 261 | 261 | zBuf[iBuf++] = '\n'; |
| 262 | 262 | comment_calc_indent(zCurrent, origIndent, trimCrLf, trimSpace, |
| 263 | 263 | &index); |
| 264 | - for ( i=0; i<origIndent; i++ ){ | |
| 264 | + for( i=0; i<origIndent; i++ ){ | |
| 265 | 265 | zBuf[iBuf++] = ' '; |
| 266 | 266 | } |
| 267 | 267 | maxChars = lineChars; |
| 268 | 268 | } |
| 269 | 269 | } |
| @@ -315,12 +315,11 @@ | ||
| 315 | 315 | (zLine[index]&0xc0)==0x80 ){ /* UTF-8 trail byte 10vvvvvv */ |
| 316 | 316 | cchUTF8++; |
| 317 | 317 | zBuf[iBuf++] = zLine[index++]; |
| 318 | 318 | } |
| 319 | 319 | maxChars--; |
| 320 | - } | |
| 321 | - else { | |
| 320 | + }else{ | |
| 322 | 321 | zBuf[iBuf++] = c; |
| 323 | 322 | maxChars -= useChars; |
| 324 | 323 | } |
| 325 | 324 | if( maxChars<=0 ) break; |
| 326 | 325 | if( c=='\n' ) break; |
| @@ -328,11 +327,11 @@ | ||
| 328 | 327 | if( charCnt>0 ){ |
| 329 | 328 | zBuf[iBuf++] = '\n'; |
| 330 | 329 | lineCnt++; |
| 331 | 330 | } |
| 332 | 331 | /* Flush the remaining output buffer. */ |
| 333 | - if( iBuf>0 ) { | |
| 332 | + if( iBuf>0 ){ | |
| 334 | 333 | zBuf[iBuf]=0; |
| 335 | 334 | iBuf=0; |
| 336 | 335 | fossil_print("%s", zBuf); |
| 337 | 336 | } |
| 338 | 337 | if( pLineCnt ){ |
| 339 | 338 |
| --- src/comformat.c | |
| +++ src/comformat.c | |
| @@ -232,11 +232,11 @@ | |
| 232 | #endif |
| 233 | if( indent>sizeof(zBuf)-6 ) /* Limit initial indent to fit output buffer. */ |
| 234 | indent = sizeof(zBuf)-6; |
| 235 | comment_calc_indent(zLine, indent, trimCrLf, trimSpace, &index); |
| 236 | if( indent>0 ){ |
| 237 | for ( i=0; i<indent; i++ ){ |
| 238 | zBuf[iBuf++] = ' '; |
| 239 | } |
| 240 | } |
| 241 | if( origIndent>sizeof(zBuf)-6 ) /* Limit line indent to fit output buffer. */ |
| 242 | origIndent = sizeof(zBuf)-6; |
| @@ -259,11 +259,11 @@ | |
| 259 | const char *zCurrent = &zLine[index]; |
| 260 | if( comment_check_orig(zOrigText, zCurrent, &charCnt, &lineCnt) ){ |
| 261 | zBuf[iBuf++] = '\n'; |
| 262 | comment_calc_indent(zCurrent, origIndent, trimCrLf, trimSpace, |
| 263 | &index); |
| 264 | for ( i=0; i<origIndent; i++ ){ |
| 265 | zBuf[iBuf++] = ' '; |
| 266 | } |
| 267 | maxChars = lineChars; |
| 268 | } |
| 269 | } |
| @@ -315,12 +315,11 @@ | |
| 315 | (zLine[index]&0xc0)==0x80 ){ /* UTF-8 trail byte 10vvvvvv */ |
| 316 | cchUTF8++; |
| 317 | zBuf[iBuf++] = zLine[index++]; |
| 318 | } |
| 319 | maxChars--; |
| 320 | } |
| 321 | else { |
| 322 | zBuf[iBuf++] = c; |
| 323 | maxChars -= useChars; |
| 324 | } |
| 325 | if( maxChars<=0 ) break; |
| 326 | if( c=='\n' ) break; |
| @@ -328,11 +327,11 @@ | |
| 328 | if( charCnt>0 ){ |
| 329 | zBuf[iBuf++] = '\n'; |
| 330 | lineCnt++; |
| 331 | } |
| 332 | /* Flush the remaining output buffer. */ |
| 333 | if( iBuf>0 ) { |
| 334 | zBuf[iBuf]=0; |
| 335 | iBuf=0; |
| 336 | fossil_print("%s", zBuf); |
| 337 | } |
| 338 | if( pLineCnt ){ |
| 339 |
| --- src/comformat.c | |
| +++ src/comformat.c | |
| @@ -232,11 +232,11 @@ | |
| 232 | #endif |
| 233 | if( indent>sizeof(zBuf)-6 ) /* Limit initial indent to fit output buffer. */ |
| 234 | indent = sizeof(zBuf)-6; |
| 235 | comment_calc_indent(zLine, indent, trimCrLf, trimSpace, &index); |
| 236 | if( indent>0 ){ |
| 237 | for( i=0; i<indent; i++ ){ |
| 238 | zBuf[iBuf++] = ' '; |
| 239 | } |
| 240 | } |
| 241 | if( origIndent>sizeof(zBuf)-6 ) /* Limit line indent to fit output buffer. */ |
| 242 | origIndent = sizeof(zBuf)-6; |
| @@ -259,11 +259,11 @@ | |
| 259 | const char *zCurrent = &zLine[index]; |
| 260 | if( comment_check_orig(zOrigText, zCurrent, &charCnt, &lineCnt) ){ |
| 261 | zBuf[iBuf++] = '\n'; |
| 262 | comment_calc_indent(zCurrent, origIndent, trimCrLf, trimSpace, |
| 263 | &index); |
| 264 | for( i=0; i<origIndent; i++ ){ |
| 265 | zBuf[iBuf++] = ' '; |
| 266 | } |
| 267 | maxChars = lineChars; |
| 268 | } |
| 269 | } |
| @@ -315,12 +315,11 @@ | |
| 315 | (zLine[index]&0xc0)==0x80 ){ /* UTF-8 trail byte 10vvvvvv */ |
| 316 | cchUTF8++; |
| 317 | zBuf[iBuf++] = zLine[index++]; |
| 318 | } |
| 319 | maxChars--; |
| 320 | }else{ |
| 321 | zBuf[iBuf++] = c; |
| 322 | maxChars -= useChars; |
| 323 | } |
| 324 | if( maxChars<=0 ) break; |
| 325 | if( c=='\n' ) break; |
| @@ -328,11 +327,11 @@ | |
| 327 | if( charCnt>0 ){ |
| 328 | zBuf[iBuf++] = '\n'; |
| 329 | lineCnt++; |
| 330 | } |
| 331 | /* Flush the remaining output buffer. */ |
| 332 | if( iBuf>0 ){ |
| 333 | zBuf[iBuf]=0; |
| 334 | iBuf=0; |
| 335 | fossil_print("%s", zBuf); |
| 336 | } |
| 337 | if( pLineCnt ){ |
| 338 |