Fossil SCM

Fix an assert() that fires if the "stash" command is used after having done an "rm". Ticket [3ce0ea97522581]

drh 2011-07-13 21:15 trunk
Commit 336e194c4d1e41a39fd788e038000c03aa8dc0f9
1 file changed +1
--- src/stash.c
+++ src/stash.c
@@ -100,10 +100,11 @@
100100
if( rid==0 ){
101101
/* A new file */
102102
blob_read_from_file(&content, zPath);
103103
db_bind_blob(&ins, ":content", &content);
104104
}else if( deleted ){
105
+ blob_zero(&content);
105106
db_bind_null(&ins, ":content");
106107
}else{
107108
/* A modified file */
108109
Blob orig;
109110
Blob disk;
110111
--- src/stash.c
+++ src/stash.c
@@ -100,10 +100,11 @@
100 if( rid==0 ){
101 /* A new file */
102 blob_read_from_file(&content, zPath);
103 db_bind_blob(&ins, ":content", &content);
104 }else if( deleted ){
 
105 db_bind_null(&ins, ":content");
106 }else{
107 /* A modified file */
108 Blob orig;
109 Blob disk;
110
--- src/stash.c
+++ src/stash.c
@@ -100,10 +100,11 @@
100 if( rid==0 ){
101 /* A new file */
102 blob_read_from_file(&content, zPath);
103 db_bind_blob(&ins, ":content", &content);
104 }else if( deleted ){
105 blob_zero(&content);
106 db_bind_null(&ins, ":content");
107 }else{
108 /* A modified file */
109 Blob orig;
110 Blob disk;
111

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button