Fossil SCM

Corrected a JSON-mode result code when db rebuild is required.

stephan 2011-09-29 21:55 UTC json
Commit 44644d43dc946ef139b691408686753f49df7a36
1 file changed +1
+1
--- src/db.c
+++ src/db.c
@@ -953,10 +953,11 @@
953953
** Verify that the repository schema is correct. If it is not correct,
954954
** issue a fatal error and die.
955955
*/
956956
void db_verify_schema(void){
957957
if( db_schema_is_outofdate() ){
958
+ g.json.resultCode = FSL_JSON_E_DB_NEEDS_REBUILD;
958959
fossil_warning("incorrect repository schema version");
959960
fossil_warning("your repository has schema version \"%s\" "
960961
"but this binary expects version \"%s\"",
961962
db_get("aux-schema",0), AUX_SCHEMA);
962963
fossil_fatal("run \"fossil rebuild\" to fix this problem");
963964
--- src/db.c
+++ src/db.c
@@ -953,10 +953,11 @@
953 ** Verify that the repository schema is correct. If it is not correct,
954 ** issue a fatal error and die.
955 */
956 void db_verify_schema(void){
957 if( db_schema_is_outofdate() ){
 
958 fossil_warning("incorrect repository schema version");
959 fossil_warning("your repository has schema version \"%s\" "
960 "but this binary expects version \"%s\"",
961 db_get("aux-schema",0), AUX_SCHEMA);
962 fossil_fatal("run \"fossil rebuild\" to fix this problem");
963
--- src/db.c
+++ src/db.c
@@ -953,10 +953,11 @@
953 ** Verify that the repository schema is correct. If it is not correct,
954 ** issue a fatal error and die.
955 */
956 void db_verify_schema(void){
957 if( db_schema_is_outofdate() ){
958 g.json.resultCode = FSL_JSON_E_DB_NEEDS_REBUILD;
959 fossil_warning("incorrect repository schema version");
960 fossil_warning("your repository has schema version \"%s\" "
961 "but this binary expects version \"%s\"",
962 db_get("aux-schema",0), AUX_SCHEMA);
963 fossil_fatal("run \"fossil rebuild\" to fix this problem");
964

Keyboard Shortcuts

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