Fossil SCM
Begin the transaction block before inserting any content.
Commit
1b6635a47fd8a1adbb9448f03b442f9bf5dc7faf
Parent
f65fe580e7c4847…
1 file changed
+1
-1
+1
-1
| --- src/tkt.c | ||
| +++ src/tkt.c | ||
| @@ -546,10 +546,11 @@ | ||
| 546 | 546 | Blob *pTicket, /* The text of the ticket change record */ |
| 547 | 547 | const char *zTktId, /* The ticket to which this change is applied */ |
| 548 | 548 | int needMod /* True if moderation is needed */ |
| 549 | 549 | ){ |
| 550 | 550 | int result; |
| 551 | + manifest_crosslink_begin(); | |
| 551 | 552 | int rid = content_put_ex(pTicket, 0, 0, 0, needMod); |
| 552 | 553 | if( rid==0 ){ |
| 553 | 554 | fossil_fatal("trouble committing ticket: %s", g.zErrMsg); |
| 554 | 555 | } |
| 555 | 556 | if( needMod ){ |
| @@ -560,11 +561,10 @@ | ||
| 560 | 561 | ); |
| 561 | 562 | }else{ |
| 562 | 563 | db_multi_exec("INSERT OR IGNORE INTO unsent VALUES(%d);", rid); |
| 563 | 564 | db_multi_exec("INSERT OR IGNORE INTO unclustered VALUES(%d);", rid); |
| 564 | 565 | } |
| 565 | - manifest_crosslink_begin(); | |
| 566 | 566 | result = (manifest_crosslink(rid, pTicket, MC_NONE)==0); |
| 567 | 567 | assert( blob_is_reset(pTicket) ); |
| 568 | 568 | if( !result ){ |
| 569 | 569 | result = manifest_crosslink_end(MC_PERMIT_HOOKS); |
| 570 | 570 | }else{ |
| 571 | 571 |
| --- src/tkt.c | |
| +++ src/tkt.c | |
| @@ -546,10 +546,11 @@ | |
| 546 | Blob *pTicket, /* The text of the ticket change record */ |
| 547 | const char *zTktId, /* The ticket to which this change is applied */ |
| 548 | int needMod /* True if moderation is needed */ |
| 549 | ){ |
| 550 | int result; |
| 551 | int rid = content_put_ex(pTicket, 0, 0, 0, needMod); |
| 552 | if( rid==0 ){ |
| 553 | fossil_fatal("trouble committing ticket: %s", g.zErrMsg); |
| 554 | } |
| 555 | if( needMod ){ |
| @@ -560,11 +561,10 @@ | |
| 560 | ); |
| 561 | }else{ |
| 562 | db_multi_exec("INSERT OR IGNORE INTO unsent VALUES(%d);", rid); |
| 563 | db_multi_exec("INSERT OR IGNORE INTO unclustered VALUES(%d);", rid); |
| 564 | } |
| 565 | manifest_crosslink_begin(); |
| 566 | result = (manifest_crosslink(rid, pTicket, MC_NONE)==0); |
| 567 | assert( blob_is_reset(pTicket) ); |
| 568 | if( !result ){ |
| 569 | result = manifest_crosslink_end(MC_PERMIT_HOOKS); |
| 570 | }else{ |
| 571 |
| --- src/tkt.c | |
| +++ src/tkt.c | |
| @@ -546,10 +546,11 @@ | |
| 546 | Blob *pTicket, /* The text of the ticket change record */ |
| 547 | const char *zTktId, /* The ticket to which this change is applied */ |
| 548 | int needMod /* True if moderation is needed */ |
| 549 | ){ |
| 550 | int result; |
| 551 | manifest_crosslink_begin(); |
| 552 | int rid = content_put_ex(pTicket, 0, 0, 0, needMod); |
| 553 | if( rid==0 ){ |
| 554 | fossil_fatal("trouble committing ticket: %s", g.zErrMsg); |
| 555 | } |
| 556 | if( needMod ){ |
| @@ -560,11 +561,10 @@ | |
| 561 | ); |
| 562 | }else{ |
| 563 | db_multi_exec("INSERT OR IGNORE INTO unsent VALUES(%d);", rid); |
| 564 | db_multi_exec("INSERT OR IGNORE INTO unclustered VALUES(%d);", rid); |
| 565 | } |
| 566 | result = (manifest_crosslink(rid, pTicket, MC_NONE)==0); |
| 567 | assert( blob_is_reset(pTicket) ); |
| 568 | if( !result ){ |
| 569 | result = manifest_crosslink_end(MC_PERMIT_HOOKS); |
| 570 | }else{ |
| 571 |