Fossil SCM
Cleanup blobs used by the 'all' sub-command.
Commit
52d746ed1eae3f18be48feedcd1b08253b5f3fe5
Parent
ac56af176b7d015…
1 file changed
+8
+8
| --- src/allrepo.c | ||
| +++ src/allrepo.c | ||
| @@ -286,10 +286,13 @@ | ||
| 286 | 286 | }else{ |
| 287 | 287 | db_multi_exec("%s", blob_sql_text(&sql)); |
| 288 | 288 | } |
| 289 | 289 | } |
| 290 | 290 | db_end_transaction(0); |
| 291 | + blob_reset(&sql); | |
| 292 | + blob_reset(&fn); | |
| 293 | + blob_reset(&extra); | |
| 291 | 294 | return; |
| 292 | 295 | }else if( strncmp(zCmd, "add", n)==0 ){ |
| 293 | 296 | int j; |
| 294 | 297 | Blob fn = BLOB_INITIALIZER; |
| 295 | 298 | Blob sql = BLOB_INITIALIZER; |
| @@ -315,10 +318,13 @@ | ||
| 315 | 318 | }else{ |
| 316 | 319 | db_multi_exec("%s", blob_sql_text(&sql)); |
| 317 | 320 | } |
| 318 | 321 | } |
| 319 | 322 | db_end_transaction(0); |
| 323 | + blob_reset(&sql); | |
| 324 | + blob_reset(&fn); | |
| 325 | + blob_reset(&extra); | |
| 320 | 326 | return; |
| 321 | 327 | }else if( strncmp(zCmd, "info", n)==0 ){ |
| 322 | 328 | zCmd = "info"; |
| 323 | 329 | showLabel = 1; |
| 324 | 330 | quiet = 1; |
| @@ -385,10 +391,12 @@ | ||
| 385 | 391 | if( stopOnError && rc ){ |
| 386 | 392 | break; |
| 387 | 393 | } |
| 388 | 394 | } |
| 389 | 395 | db_finalize(&q); |
| 396 | + | |
| 397 | + blob_reset(&extra); | |
| 390 | 398 | |
| 391 | 399 | /* If any repositories whose names appear in the ~/.fossil file could not |
| 392 | 400 | ** be found, remove those names from the ~/.fossil file. |
| 393 | 401 | */ |
| 394 | 402 | if( nToDel>0 ){ |
| 395 | 403 |
| --- src/allrepo.c | |
| +++ src/allrepo.c | |
| @@ -286,10 +286,13 @@ | |
| 286 | }else{ |
| 287 | db_multi_exec("%s", blob_sql_text(&sql)); |
| 288 | } |
| 289 | } |
| 290 | db_end_transaction(0); |
| 291 | return; |
| 292 | }else if( strncmp(zCmd, "add", n)==0 ){ |
| 293 | int j; |
| 294 | Blob fn = BLOB_INITIALIZER; |
| 295 | Blob sql = BLOB_INITIALIZER; |
| @@ -315,10 +318,13 @@ | |
| 315 | }else{ |
| 316 | db_multi_exec("%s", blob_sql_text(&sql)); |
| 317 | } |
| 318 | } |
| 319 | db_end_transaction(0); |
| 320 | return; |
| 321 | }else if( strncmp(zCmd, "info", n)==0 ){ |
| 322 | zCmd = "info"; |
| 323 | showLabel = 1; |
| 324 | quiet = 1; |
| @@ -385,10 +391,12 @@ | |
| 385 | if( stopOnError && rc ){ |
| 386 | break; |
| 387 | } |
| 388 | } |
| 389 | db_finalize(&q); |
| 390 | |
| 391 | /* If any repositories whose names appear in the ~/.fossil file could not |
| 392 | ** be found, remove those names from the ~/.fossil file. |
| 393 | */ |
| 394 | if( nToDel>0 ){ |
| 395 |
| --- src/allrepo.c | |
| +++ src/allrepo.c | |
| @@ -286,10 +286,13 @@ | |
| 286 | }else{ |
| 287 | db_multi_exec("%s", blob_sql_text(&sql)); |
| 288 | } |
| 289 | } |
| 290 | db_end_transaction(0); |
| 291 | blob_reset(&sql); |
| 292 | blob_reset(&fn); |
| 293 | blob_reset(&extra); |
| 294 | return; |
| 295 | }else if( strncmp(zCmd, "add", n)==0 ){ |
| 296 | int j; |
| 297 | Blob fn = BLOB_INITIALIZER; |
| 298 | Blob sql = BLOB_INITIALIZER; |
| @@ -315,10 +318,13 @@ | |
| 318 | }else{ |
| 319 | db_multi_exec("%s", blob_sql_text(&sql)); |
| 320 | } |
| 321 | } |
| 322 | db_end_transaction(0); |
| 323 | blob_reset(&sql); |
| 324 | blob_reset(&fn); |
| 325 | blob_reset(&extra); |
| 326 | return; |
| 327 | }else if( strncmp(zCmd, "info", n)==0 ){ |
| 328 | zCmd = "info"; |
| 329 | showLabel = 1; |
| 330 | quiet = 1; |
| @@ -385,10 +391,12 @@ | |
| 391 | if( stopOnError && rc ){ |
| 392 | break; |
| 393 | } |
| 394 | } |
| 395 | db_finalize(&q); |
| 396 | |
| 397 | blob_reset(&extra); |
| 398 | |
| 399 | /* If any repositories whose names appear in the ~/.fossil file could not |
| 400 | ** be found, remove those names from the ~/.fossil file. |
| 401 | */ |
| 402 | if( nToDel>0 ){ |
| 403 |