Fossil SCM
Merged in trunk for related changes.
Commit
03cce1c97786f8473cb1de50f6b1d74b2f8ccd4c2115e9a924c3e9e3fad11812
Parent
d8d9929c403eeed…
11 files changed
+14
-3
+14
-3
+1
+4
+1
-1
+1
-1
+3
-1
+1
-1
+15
-1
+1
-1
+1
-1
+14
-3
| --- src/checkin.c | ||
| +++ src/checkin.c | ||
| @@ -2103,12 +2103,17 @@ | ||
| 2103 | 2103 | useHash = find_option("hash",0,0)!=0 || find_option("sha1sum",0,0)!=0; |
| 2104 | 2104 | noSign = find_option("nosign",0,0)!=0; |
| 2105 | 2105 | privateFlag = find_option("private",0,0)!=0; |
| 2106 | 2106 | forceDelta = find_option("delta",0,0)!=0; |
| 2107 | 2107 | forceBaseline = find_option("baseline",0,0)!=0; |
| 2108 | - if( forceDelta && forceBaseline ){ | |
| 2109 | - fossil_fatal("cannot use --delta and --baseline together"); | |
| 2108 | + if( forceDelta ){ | |
| 2109 | + if( forceBaseline ){ | |
| 2110 | + fossil_fatal("cannot use --delta and --baseline together"); | |
| 2111 | + } | |
| 2112 | + if( db_get_boolean("forbid-delta-manifests",0) ){ | |
| 2113 | + fossil_fatal("delta manifests are prohibited in this repository"); | |
| 2114 | + } | |
| 2110 | 2115 | } |
| 2111 | 2116 | dryRunFlag = find_option("dry-run","n",0)!=0; |
| 2112 | 2117 | if( !dryRunFlag ){ |
| 2113 | 2118 | dryRunFlag = find_option("test",0,0)!=0; /* deprecated */ |
| 2114 | 2119 | } |
| @@ -2187,11 +2192,14 @@ | ||
| 2187 | 2192 | ** manifest) can continue to use this repository, do not create a new |
| 2188 | 2193 | ** delta-manifest unless this repository already contains one or more |
| 2189 | 2194 | ** delta-manifests, or unless the delta-manifest is explicitly requested |
| 2190 | 2195 | ** by the --delta option. |
| 2191 | 2196 | */ |
| 2192 | - if( !forceDelta && !db_get_boolean("seen-delta-manifest",0) ){ | |
| 2197 | + if( !forceDelta | |
| 2198 | + && !db_get_boolean("seen-delta-manifest",0) | |
| 2199 | + && !db_get_boolean("forbid-delta-manifests",0) | |
| 2200 | + ){ | |
| 2193 | 2201 | forceBaseline = 1; |
| 2194 | 2202 | } |
| 2195 | 2203 | |
| 2196 | 2204 | /* |
| 2197 | 2205 | ** Autosync if autosync is enabled and this is not a private check-in. |
| @@ -2659,10 +2667,11 @@ | ||
| 2659 | 2667 | /* Commit */ |
| 2660 | 2668 | db_multi_exec("DELETE FROM vvar WHERE name='ci-comment'"); |
| 2661 | 2669 | db_multi_exec("PRAGMA repository.application_id=252006673;"); |
| 2662 | 2670 | db_multi_exec("PRAGMA localdb.application_id=252006674;"); |
| 2663 | 2671 | if( dryRunFlag ){ |
| 2672 | + leaf_ambiguity_warning(nvid,nvid); | |
| 2664 | 2673 | db_end_transaction(1); |
| 2665 | 2674 | exit(1); |
| 2666 | 2675 | } |
| 2667 | 2676 | db_end_transaction(0); |
| 2668 | 2677 | |
| @@ -2681,10 +2690,12 @@ | ||
| 2681 | 2690 | int nTries = db_get_int("autosync-tries",1); |
| 2682 | 2691 | autosync_loop(syncFlags, nTries, 0); |
| 2683 | 2692 | } |
| 2684 | 2693 | if( count_nonbranch_children(vid)>1 ){ |
| 2685 | 2694 | fossil_print("**** warning: a fork has occurred *****\n"); |
| 2695 | + }else{ | |
| 2696 | + leaf_ambiguity_warning(nvid,nvid); | |
| 2686 | 2697 | } |
| 2687 | 2698 | } |
| 2688 | 2699 | |
| 2689 | 2700 | /* |
| 2690 | 2701 | ** State for the "mini-checkin" infrastructure, which enables the |
| 2691 | 2702 |
| --- src/checkin.c | |
| +++ src/checkin.c | |
| @@ -2103,12 +2103,17 @@ | |
| 2103 | useHash = find_option("hash",0,0)!=0 || find_option("sha1sum",0,0)!=0; |
| 2104 | noSign = find_option("nosign",0,0)!=0; |
| 2105 | privateFlag = find_option("private",0,0)!=0; |
| 2106 | forceDelta = find_option("delta",0,0)!=0; |
| 2107 | forceBaseline = find_option("baseline",0,0)!=0; |
| 2108 | if( forceDelta && forceBaseline ){ |
| 2109 | fossil_fatal("cannot use --delta and --baseline together"); |
| 2110 | } |
| 2111 | dryRunFlag = find_option("dry-run","n",0)!=0; |
| 2112 | if( !dryRunFlag ){ |
| 2113 | dryRunFlag = find_option("test",0,0)!=0; /* deprecated */ |
| 2114 | } |
| @@ -2187,11 +2192,14 @@ | |
| 2187 | ** manifest) can continue to use this repository, do not create a new |
| 2188 | ** delta-manifest unless this repository already contains one or more |
| 2189 | ** delta-manifests, or unless the delta-manifest is explicitly requested |
| 2190 | ** by the --delta option. |
| 2191 | */ |
| 2192 | if( !forceDelta && !db_get_boolean("seen-delta-manifest",0) ){ |
| 2193 | forceBaseline = 1; |
| 2194 | } |
| 2195 | |
| 2196 | /* |
| 2197 | ** Autosync if autosync is enabled and this is not a private check-in. |
| @@ -2659,10 +2667,11 @@ | |
| 2659 | /* Commit */ |
| 2660 | db_multi_exec("DELETE FROM vvar WHERE name='ci-comment'"); |
| 2661 | db_multi_exec("PRAGMA repository.application_id=252006673;"); |
| 2662 | db_multi_exec("PRAGMA localdb.application_id=252006674;"); |
| 2663 | if( dryRunFlag ){ |
| 2664 | db_end_transaction(1); |
| 2665 | exit(1); |
| 2666 | } |
| 2667 | db_end_transaction(0); |
| 2668 | |
| @@ -2681,10 +2690,12 @@ | |
| 2681 | int nTries = db_get_int("autosync-tries",1); |
| 2682 | autosync_loop(syncFlags, nTries, 0); |
| 2683 | } |
| 2684 | if( count_nonbranch_children(vid)>1 ){ |
| 2685 | fossil_print("**** warning: a fork has occurred *****\n"); |
| 2686 | } |
| 2687 | } |
| 2688 | |
| 2689 | /* |
| 2690 | ** State for the "mini-checkin" infrastructure, which enables the |
| 2691 |
| --- src/checkin.c | |
| +++ src/checkin.c | |
| @@ -2103,12 +2103,17 @@ | |
| 2103 | useHash = find_option("hash",0,0)!=0 || find_option("sha1sum",0,0)!=0; |
| 2104 | noSign = find_option("nosign",0,0)!=0; |
| 2105 | privateFlag = find_option("private",0,0)!=0; |
| 2106 | forceDelta = find_option("delta",0,0)!=0; |
| 2107 | forceBaseline = find_option("baseline",0,0)!=0; |
| 2108 | if( forceDelta ){ |
| 2109 | if( forceBaseline ){ |
| 2110 | fossil_fatal("cannot use --delta and --baseline together"); |
| 2111 | } |
| 2112 | if( db_get_boolean("forbid-delta-manifests",0) ){ |
| 2113 | fossil_fatal("delta manifests are prohibited in this repository"); |
| 2114 | } |
| 2115 | } |
| 2116 | dryRunFlag = find_option("dry-run","n",0)!=0; |
| 2117 | if( !dryRunFlag ){ |
| 2118 | dryRunFlag = find_option("test",0,0)!=0; /* deprecated */ |
| 2119 | } |
| @@ -2187,11 +2192,14 @@ | |
| 2192 | ** manifest) can continue to use this repository, do not create a new |
| 2193 | ** delta-manifest unless this repository already contains one or more |
| 2194 | ** delta-manifests, or unless the delta-manifest is explicitly requested |
| 2195 | ** by the --delta option. |
| 2196 | */ |
| 2197 | if( !forceDelta |
| 2198 | && !db_get_boolean("seen-delta-manifest",0) |
| 2199 | && !db_get_boolean("forbid-delta-manifests",0) |
| 2200 | ){ |
| 2201 | forceBaseline = 1; |
| 2202 | } |
| 2203 | |
| 2204 | /* |
| 2205 | ** Autosync if autosync is enabled and this is not a private check-in. |
| @@ -2659,10 +2667,11 @@ | |
| 2667 | /* Commit */ |
| 2668 | db_multi_exec("DELETE FROM vvar WHERE name='ci-comment'"); |
| 2669 | db_multi_exec("PRAGMA repository.application_id=252006673;"); |
| 2670 | db_multi_exec("PRAGMA localdb.application_id=252006674;"); |
| 2671 | if( dryRunFlag ){ |
| 2672 | leaf_ambiguity_warning(nvid,nvid); |
| 2673 | db_end_transaction(1); |
| 2674 | exit(1); |
| 2675 | } |
| 2676 | db_end_transaction(0); |
| 2677 | |
| @@ -2681,10 +2690,12 @@ | |
| 2690 | int nTries = db_get_int("autosync-tries",1); |
| 2691 | autosync_loop(syncFlags, nTries, 0); |
| 2692 | } |
| 2693 | if( count_nonbranch_children(vid)>1 ){ |
| 2694 | fossil_print("**** warning: a fork has occurred *****\n"); |
| 2695 | }else{ |
| 2696 | leaf_ambiguity_warning(nvid,nvid); |
| 2697 | } |
| 2698 | } |
| 2699 | |
| 2700 | /* |
| 2701 | ** State for the "mini-checkin" infrastructure, which enables the |
| 2702 |
+14
-3
| --- src/checkin.c | ||
| +++ src/checkin.c | ||
| @@ -2103,12 +2103,17 @@ | ||
| 2103 | 2103 | useHash = find_option("hash",0,0)!=0 || find_option("sha1sum",0,0)!=0; |
| 2104 | 2104 | noSign = find_option("nosign",0,0)!=0; |
| 2105 | 2105 | privateFlag = find_option("private",0,0)!=0; |
| 2106 | 2106 | forceDelta = find_option("delta",0,0)!=0; |
| 2107 | 2107 | forceBaseline = find_option("baseline",0,0)!=0; |
| 2108 | - if( forceDelta && forceBaseline ){ | |
| 2109 | - fossil_fatal("cannot use --delta and --baseline together"); | |
| 2108 | + if( forceDelta ){ | |
| 2109 | + if( forceBaseline ){ | |
| 2110 | + fossil_fatal("cannot use --delta and --baseline together"); | |
| 2111 | + } | |
| 2112 | + if( db_get_boolean("forbid-delta-manifests",0) ){ | |
| 2113 | + fossil_fatal("delta manifests are prohibited in this repository"); | |
| 2114 | + } | |
| 2110 | 2115 | } |
| 2111 | 2116 | dryRunFlag = find_option("dry-run","n",0)!=0; |
| 2112 | 2117 | if( !dryRunFlag ){ |
| 2113 | 2118 | dryRunFlag = find_option("test",0,0)!=0; /* deprecated */ |
| 2114 | 2119 | } |
| @@ -2187,11 +2192,14 @@ | ||
| 2187 | 2192 | ** manifest) can continue to use this repository, do not create a new |
| 2188 | 2193 | ** delta-manifest unless this repository already contains one or more |
| 2189 | 2194 | ** delta-manifests, or unless the delta-manifest is explicitly requested |
| 2190 | 2195 | ** by the --delta option. |
| 2191 | 2196 | */ |
| 2192 | - if( !forceDelta && !db_get_boolean("seen-delta-manifest",0) ){ | |
| 2197 | + if( !forceDelta | |
| 2198 | + && !db_get_boolean("seen-delta-manifest",0) | |
| 2199 | + && !db_get_boolean("forbid-delta-manifests",0) | |
| 2200 | + ){ | |
| 2193 | 2201 | forceBaseline = 1; |
| 2194 | 2202 | } |
| 2195 | 2203 | |
| 2196 | 2204 | /* |
| 2197 | 2205 | ** Autosync if autosync is enabled and this is not a private check-in. |
| @@ -2659,10 +2667,11 @@ | ||
| 2659 | 2667 | /* Commit */ |
| 2660 | 2668 | db_multi_exec("DELETE FROM vvar WHERE name='ci-comment'"); |
| 2661 | 2669 | db_multi_exec("PRAGMA repository.application_id=252006673;"); |
| 2662 | 2670 | db_multi_exec("PRAGMA localdb.application_id=252006674;"); |
| 2663 | 2671 | if( dryRunFlag ){ |
| 2672 | + leaf_ambiguity_warning(nvid,nvid); | |
| 2664 | 2673 | db_end_transaction(1); |
| 2665 | 2674 | exit(1); |
| 2666 | 2675 | } |
| 2667 | 2676 | db_end_transaction(0); |
| 2668 | 2677 | |
| @@ -2681,10 +2690,12 @@ | ||
| 2681 | 2690 | int nTries = db_get_int("autosync-tries",1); |
| 2682 | 2691 | autosync_loop(syncFlags, nTries, 0); |
| 2683 | 2692 | } |
| 2684 | 2693 | if( count_nonbranch_children(vid)>1 ){ |
| 2685 | 2694 | fossil_print("**** warning: a fork has occurred *****\n"); |
| 2695 | + }else{ | |
| 2696 | + leaf_ambiguity_warning(nvid,nvid); | |
| 2686 | 2697 | } |
| 2687 | 2698 | } |
| 2688 | 2699 | |
| 2689 | 2700 | /* |
| 2690 | 2701 | ** State for the "mini-checkin" infrastructure, which enables the |
| 2691 | 2702 |
| --- src/checkin.c | |
| +++ src/checkin.c | |
| @@ -2103,12 +2103,17 @@ | |
| 2103 | useHash = find_option("hash",0,0)!=0 || find_option("sha1sum",0,0)!=0; |
| 2104 | noSign = find_option("nosign",0,0)!=0; |
| 2105 | privateFlag = find_option("private",0,0)!=0; |
| 2106 | forceDelta = find_option("delta",0,0)!=0; |
| 2107 | forceBaseline = find_option("baseline",0,0)!=0; |
| 2108 | if( forceDelta && forceBaseline ){ |
| 2109 | fossil_fatal("cannot use --delta and --baseline together"); |
| 2110 | } |
| 2111 | dryRunFlag = find_option("dry-run","n",0)!=0; |
| 2112 | if( !dryRunFlag ){ |
| 2113 | dryRunFlag = find_option("test",0,0)!=0; /* deprecated */ |
| 2114 | } |
| @@ -2187,11 +2192,14 @@ | |
| 2187 | ** manifest) can continue to use this repository, do not create a new |
| 2188 | ** delta-manifest unless this repository already contains one or more |
| 2189 | ** delta-manifests, or unless the delta-manifest is explicitly requested |
| 2190 | ** by the --delta option. |
| 2191 | */ |
| 2192 | if( !forceDelta && !db_get_boolean("seen-delta-manifest",0) ){ |
| 2193 | forceBaseline = 1; |
| 2194 | } |
| 2195 | |
| 2196 | /* |
| 2197 | ** Autosync if autosync is enabled and this is not a private check-in. |
| @@ -2659,10 +2667,11 @@ | |
| 2659 | /* Commit */ |
| 2660 | db_multi_exec("DELETE FROM vvar WHERE name='ci-comment'"); |
| 2661 | db_multi_exec("PRAGMA repository.application_id=252006673;"); |
| 2662 | db_multi_exec("PRAGMA localdb.application_id=252006674;"); |
| 2663 | if( dryRunFlag ){ |
| 2664 | db_end_transaction(1); |
| 2665 | exit(1); |
| 2666 | } |
| 2667 | db_end_transaction(0); |
| 2668 | |
| @@ -2681,10 +2690,12 @@ | |
| 2681 | int nTries = db_get_int("autosync-tries",1); |
| 2682 | autosync_loop(syncFlags, nTries, 0); |
| 2683 | } |
| 2684 | if( count_nonbranch_children(vid)>1 ){ |
| 2685 | fossil_print("**** warning: a fork has occurred *****\n"); |
| 2686 | } |
| 2687 | } |
| 2688 | |
| 2689 | /* |
| 2690 | ** State for the "mini-checkin" infrastructure, which enables the |
| 2691 |
| --- src/checkin.c | |
| +++ src/checkin.c | |
| @@ -2103,12 +2103,17 @@ | |
| 2103 | useHash = find_option("hash",0,0)!=0 || find_option("sha1sum",0,0)!=0; |
| 2104 | noSign = find_option("nosign",0,0)!=0; |
| 2105 | privateFlag = find_option("private",0,0)!=0; |
| 2106 | forceDelta = find_option("delta",0,0)!=0; |
| 2107 | forceBaseline = find_option("baseline",0,0)!=0; |
| 2108 | if( forceDelta ){ |
| 2109 | if( forceBaseline ){ |
| 2110 | fossil_fatal("cannot use --delta and --baseline together"); |
| 2111 | } |
| 2112 | if( db_get_boolean("forbid-delta-manifests",0) ){ |
| 2113 | fossil_fatal("delta manifests are prohibited in this repository"); |
| 2114 | } |
| 2115 | } |
| 2116 | dryRunFlag = find_option("dry-run","n",0)!=0; |
| 2117 | if( !dryRunFlag ){ |
| 2118 | dryRunFlag = find_option("test",0,0)!=0; /* deprecated */ |
| 2119 | } |
| @@ -2187,11 +2192,14 @@ | |
| 2192 | ** manifest) can continue to use this repository, do not create a new |
| 2193 | ** delta-manifest unless this repository already contains one or more |
| 2194 | ** delta-manifests, or unless the delta-manifest is explicitly requested |
| 2195 | ** by the --delta option. |
| 2196 | */ |
| 2197 | if( !forceDelta |
| 2198 | && !db_get_boolean("seen-delta-manifest",0) |
| 2199 | && !db_get_boolean("forbid-delta-manifests",0) |
| 2200 | ){ |
| 2201 | forceBaseline = 1; |
| 2202 | } |
| 2203 | |
| 2204 | /* |
| 2205 | ** Autosync if autosync is enabled and this is not a private check-in. |
| @@ -2659,10 +2667,11 @@ | |
| 2667 | /* Commit */ |
| 2668 | db_multi_exec("DELETE FROM vvar WHERE name='ci-comment'"); |
| 2669 | db_multi_exec("PRAGMA repository.application_id=252006673;"); |
| 2670 | db_multi_exec("PRAGMA localdb.application_id=252006674;"); |
| 2671 | if( dryRunFlag ){ |
| 2672 | leaf_ambiguity_warning(nvid,nvid); |
| 2673 | db_end_transaction(1); |
| 2674 | exit(1); |
| 2675 | } |
| 2676 | db_end_transaction(0); |
| 2677 | |
| @@ -2681,10 +2690,12 @@ | |
| 2690 | int nTries = db_get_int("autosync-tries",1); |
| 2691 | autosync_loop(syncFlags, nTries, 0); |
| 2692 | } |
| 2693 | if( count_nonbranch_children(vid)>1 ){ |
| 2694 | fossil_print("**** warning: a fork has occurred *****\n"); |
| 2695 | }else{ |
| 2696 | leaf_ambiguity_warning(nvid,nvid); |
| 2697 | } |
| 2698 | } |
| 2699 | |
| 2700 | /* |
| 2701 | ** State for the "mini-checkin" infrastructure, which enables the |
| 2702 |
+1
| --- src/configure.c | ||
| +++ src/configure.c | ||
| @@ -147,10 +147,11 @@ | ||
| 147 | 147 | { "parent-project-code", CONFIGSET_PROJ }, |
| 148 | 148 | { "parent-project-name", CONFIGSET_PROJ }, |
| 149 | 149 | { "hash-policy", CONFIGSET_PROJ }, |
| 150 | 150 | { "comment-format", CONFIGSET_PROJ }, |
| 151 | 151 | { "mimetypes", CONFIGSET_PROJ }, |
| 152 | + { "forbid-delta-manifests", CONFIGSET_PROJ }, | |
| 152 | 153 | |
| 153 | 154 | #ifdef FOSSIL_ENABLE_LEGACY_MV_RM |
| 154 | 155 | { "mv-rm-files", CONFIGSET_PROJ }, |
| 155 | 156 | #endif |
| 156 | 157 | |
| 157 | 158 |
| --- src/configure.c | |
| +++ src/configure.c | |
| @@ -147,10 +147,11 @@ | |
| 147 | { "parent-project-code", CONFIGSET_PROJ }, |
| 148 | { "parent-project-name", CONFIGSET_PROJ }, |
| 149 | { "hash-policy", CONFIGSET_PROJ }, |
| 150 | { "comment-format", CONFIGSET_PROJ }, |
| 151 | { "mimetypes", CONFIGSET_PROJ }, |
| 152 | |
| 153 | #ifdef FOSSIL_ENABLE_LEGACY_MV_RM |
| 154 | { "mv-rm-files", CONFIGSET_PROJ }, |
| 155 | #endif |
| 156 | |
| 157 |
| --- src/configure.c | |
| +++ src/configure.c | |
| @@ -147,10 +147,11 @@ | |
| 147 | { "parent-project-code", CONFIGSET_PROJ }, |
| 148 | { "parent-project-name", CONFIGSET_PROJ }, |
| 149 | { "hash-policy", CONFIGSET_PROJ }, |
| 150 | { "comment-format", CONFIGSET_PROJ }, |
| 151 | { "mimetypes", CONFIGSET_PROJ }, |
| 152 | { "forbid-delta-manifests", CONFIGSET_PROJ }, |
| 153 | |
| 154 | #ifdef FOSSIL_ENABLE_LEGACY_MV_RM |
| 155 | { "mv-rm-files", CONFIGSET_PROJ }, |
| 156 | #endif |
| 157 | |
| 158 |
M
src/db.c
+4
| --- src/db.c | ||
| +++ src/db.c | ||
| @@ -3556,10 +3556,14 @@ | ||
| 3556 | 3556 | /* |
| 3557 | 3557 | ** SETTING: pgp-command width=40 |
| 3558 | 3558 | ** Command used to clear-sign manifests at check-in. |
| 3559 | 3559 | ** Default value is "gpg --clearsign -o" |
| 3560 | 3560 | */ |
| 3561 | +/* | |
| 3562 | +** SETTING: forbid-delta-manifests boolean default=off | |
| 3563 | +** If enabled, new delta manifests are prohibited. | |
| 3564 | +*/ | |
| 3561 | 3565 | /* |
| 3562 | 3566 | ** SETTING: proxy width=32 default=off |
| 3563 | 3567 | ** URL of the HTTP proxy. If undefined or "off" then |
| 3564 | 3568 | ** the "http_proxy" environment variable is consulted. |
| 3565 | 3569 | ** If the http_proxy environment variable is undefined |
| 3566 | 3570 |
| --- src/db.c | |
| +++ src/db.c | |
| @@ -3556,10 +3556,14 @@ | |
| 3556 | /* |
| 3557 | ** SETTING: pgp-command width=40 |
| 3558 | ** Command used to clear-sign manifests at check-in. |
| 3559 | ** Default value is "gpg --clearsign -o" |
| 3560 | */ |
| 3561 | /* |
| 3562 | ** SETTING: proxy width=32 default=off |
| 3563 | ** URL of the HTTP proxy. If undefined or "off" then |
| 3564 | ** the "http_proxy" environment variable is consulted. |
| 3565 | ** If the http_proxy environment variable is undefined |
| 3566 |
| --- src/db.c | |
| +++ src/db.c | |
| @@ -3556,10 +3556,14 @@ | |
| 3556 | /* |
| 3557 | ** SETTING: pgp-command width=40 |
| 3558 | ** Command used to clear-sign manifests at check-in. |
| 3559 | ** Default value is "gpg --clearsign -o" |
| 3560 | */ |
| 3561 | /* |
| 3562 | ** SETTING: forbid-delta-manifests boolean default=off |
| 3563 | ** If enabled, new delta manifests are prohibited. |
| 3564 | */ |
| 3565 | /* |
| 3566 | ** SETTING: proxy width=32 default=off |
| 3567 | ** URL of the HTTP proxy. If undefined or "off" then |
| 3568 | ** the "http_proxy" environment variable is consulted. |
| 3569 | ** If the http_proxy environment variable is undefined |
| 3570 |
+1
-1
| --- src/diff.c | ||
| +++ src/diff.c | ||
| @@ -2,11 +2,11 @@ | ||
| 2 | 2 | ** Copyright (c) 2007 D. Richard Hipp |
| 3 | 3 | ** |
| 4 | 4 | ** This program is free software; you can redistribute it and/or |
| 5 | 5 | ** modify it under the terms of the Simplified BSD License (also |
| 6 | 6 | ** known as the "2-Clause License" or "FreeBSD License".) |
| 7 | - | |
| 7 | +** | |
| 8 | 8 | ** This program is distributed in the hope that it will be useful, |
| 9 | 9 | ** but without any warranty; without even the implied warranty of |
| 10 | 10 | ** merchantability or fitness for a particular purpose. |
| 11 | 11 | ** |
| 12 | 12 | ** Author contact information: |
| 13 | 13 |
| --- src/diff.c | |
| +++ src/diff.c | |
| @@ -2,11 +2,11 @@ | |
| 2 | ** Copyright (c) 2007 D. Richard Hipp |
| 3 | ** |
| 4 | ** This program is free software; you can redistribute it and/or |
| 5 | ** modify it under the terms of the Simplified BSD License (also |
| 6 | ** known as the "2-Clause License" or "FreeBSD License".) |
| 7 | |
| 8 | ** This program is distributed in the hope that it will be useful, |
| 9 | ** but without any warranty; without even the implied warranty of |
| 10 | ** merchantability or fitness for a particular purpose. |
| 11 | ** |
| 12 | ** Author contact information: |
| 13 |
| --- src/diff.c | |
| +++ src/diff.c | |
| @@ -2,11 +2,11 @@ | |
| 2 | ** Copyright (c) 2007 D. Richard Hipp |
| 3 | ** |
| 4 | ** This program is free software; you can redistribute it and/or |
| 5 | ** modify it under the terms of the Simplified BSD License (also |
| 6 | ** known as the "2-Clause License" or "FreeBSD License".) |
| 7 | ** |
| 8 | ** This program is distributed in the hope that it will be useful, |
| 9 | ** but without any warranty; without even the implied warranty of |
| 10 | ** merchantability or fitness for a particular purpose. |
| 11 | ** |
| 12 | ** Author contact information: |
| 13 |
+1
-1
| --- src/file.c | ||
| +++ src/file.c | ||
| @@ -294,11 +294,11 @@ | ||
| 294 | 294 | ** |
| 295 | 295 | ** On windows, this routine returns only PERM_REG. |
| 296 | 296 | */ |
| 297 | 297 | int file_perm(const char *zFilename, int eFType){ |
| 298 | 298 | #if !defined(_WIN32) |
| 299 | - if( !getStat(zFilename, RepoFILE) ){ | |
| 299 | + if( !getStat(zFilename, eFType) ){ | |
| 300 | 300 | if( S_ISREG(fx.fileStat.st_mode) && ((S_IXUSR)&fx.fileStat.st_mode)!=0 ) |
| 301 | 301 | return PERM_EXE; |
| 302 | 302 | else if( db_allow_symlinks() && S_ISLNK(fx.fileStat.st_mode) ) |
| 303 | 303 | return PERM_LNK; |
| 304 | 304 | } |
| 305 | 305 |
| --- src/file.c | |
| +++ src/file.c | |
| @@ -294,11 +294,11 @@ | |
| 294 | ** |
| 295 | ** On windows, this routine returns only PERM_REG. |
| 296 | */ |
| 297 | int file_perm(const char *zFilename, int eFType){ |
| 298 | #if !defined(_WIN32) |
| 299 | if( !getStat(zFilename, RepoFILE) ){ |
| 300 | if( S_ISREG(fx.fileStat.st_mode) && ((S_IXUSR)&fx.fileStat.st_mode)!=0 ) |
| 301 | return PERM_EXE; |
| 302 | else if( db_allow_symlinks() && S_ISLNK(fx.fileStat.st_mode) ) |
| 303 | return PERM_LNK; |
| 304 | } |
| 305 |
| --- src/file.c | |
| +++ src/file.c | |
| @@ -294,11 +294,11 @@ | |
| 294 | ** |
| 295 | ** On windows, this routine returns only PERM_REG. |
| 296 | */ |
| 297 | int file_perm(const char *zFilename, int eFType){ |
| 298 | #if !defined(_WIN32) |
| 299 | if( !getStat(zFilename, eFType) ){ |
| 300 | if( S_ISREG(fx.fileStat.st_mode) && ((S_IXUSR)&fx.fileStat.st_mode)!=0 ) |
| 301 | return PERM_EXE; |
| 302 | else if( db_allow_symlinks() && S_ISLNK(fx.fileStat.st_mode) ) |
| 303 | return PERM_LNK; |
| 304 | } |
| 305 |
+3
-1
| --- src/graph.c | ||
| +++ src/graph.c | ||
| @@ -534,17 +534,19 @@ | ||
| 534 | 534 | pParent->idxTop = pRow->idxTop; |
| 535 | 535 | } |
| 536 | 536 | } |
| 537 | 537 | |
| 538 | 538 | if( tmFlags & TIMELINE_FILLGAPS ){ |
| 539 | - /* If a node has no pChild and there is a node higher up in the graph | |
| 539 | + /* If a node has no pChild in the graph | |
| 540 | + ** and there is a node higher up in the graph | |
| 540 | 541 | ** that is in the same branch and has no in-graph parent, then |
| 541 | 542 | ** make the lower node a step-child of the upper node. This will |
| 542 | 543 | ** be represented on the graph by a thick dotted line without an arrowhead. |
| 543 | 544 | */ |
| 544 | 545 | for(pRow=p->pFirst; pRow; pRow=pRow->pNext){ |
| 545 | 546 | if( pRow->pChild ) continue; |
| 547 | + if( pRow->isLeaf ) continue; | |
| 546 | 548 | for(pLoop=pRow->pPrev; pLoop; pLoop=pLoop->pPrev){ |
| 547 | 549 | if( pLoop->nParent>0 |
| 548 | 550 | && pLoop->zBranch==pRow->zBranch |
| 549 | 551 | && hashFind(p,pLoop->aParent[0])==0 |
| 550 | 552 | ){ |
| 551 | 553 |
| --- src/graph.c | |
| +++ src/graph.c | |
| @@ -534,17 +534,19 @@ | |
| 534 | pParent->idxTop = pRow->idxTop; |
| 535 | } |
| 536 | } |
| 537 | |
| 538 | if( tmFlags & TIMELINE_FILLGAPS ){ |
| 539 | /* If a node has no pChild and there is a node higher up in the graph |
| 540 | ** that is in the same branch and has no in-graph parent, then |
| 541 | ** make the lower node a step-child of the upper node. This will |
| 542 | ** be represented on the graph by a thick dotted line without an arrowhead. |
| 543 | */ |
| 544 | for(pRow=p->pFirst; pRow; pRow=pRow->pNext){ |
| 545 | if( pRow->pChild ) continue; |
| 546 | for(pLoop=pRow->pPrev; pLoop; pLoop=pLoop->pPrev){ |
| 547 | if( pLoop->nParent>0 |
| 548 | && pLoop->zBranch==pRow->zBranch |
| 549 | && hashFind(p,pLoop->aParent[0])==0 |
| 550 | ){ |
| 551 |
| --- src/graph.c | |
| +++ src/graph.c | |
| @@ -534,17 +534,19 @@ | |
| 534 | pParent->idxTop = pRow->idxTop; |
| 535 | } |
| 536 | } |
| 537 | |
| 538 | if( tmFlags & TIMELINE_FILLGAPS ){ |
| 539 | /* If a node has no pChild in the graph |
| 540 | ** and there is a node higher up in the graph |
| 541 | ** that is in the same branch and has no in-graph parent, then |
| 542 | ** make the lower node a step-child of the upper node. This will |
| 543 | ** be represented on the graph by a thick dotted line without an arrowhead. |
| 544 | */ |
| 545 | for(pRow=p->pFirst; pRow; pRow=pRow->pNext){ |
| 546 | if( pRow->pChild ) continue; |
| 547 | if( pRow->isLeaf ) continue; |
| 548 | for(pLoop=pRow->pPrev; pLoop; pLoop=pLoop->pPrev){ |
| 549 | if( pLoop->nParent>0 |
| 550 | && pLoop->zBranch==pRow->zBranch |
| 551 | && hashFind(p,pLoop->aParent[0])==0 |
| 552 | ){ |
| 553 |
+1
-1
| --- src/tar.c | ||
| +++ src/tar.c | ||
| @@ -443,11 +443,11 @@ | ||
| 443 | 443 | tar_begin(-1); |
| 444 | 444 | for(i=3; i<g.argc; i++){ |
| 445 | 445 | Blob file; |
| 446 | 446 | blob_zero(&file); |
| 447 | 447 | blob_read_from_file(&file, g.argv[i], eFType); |
| 448 | - tar_add_file(g.argv[i], &file, file_perm(0,0), file_mtime(0,0)); | |
| 448 | + tar_add_file(g.argv[i], &file, file_perm(0,eFType), file_mtime(0,eFType)); | |
| 449 | 449 | blob_reset(&file); |
| 450 | 450 | } |
| 451 | 451 | tar_finish(&zip); |
| 452 | 452 | blob_write_to_file(&zip, g.argv[2]); |
| 453 | 453 | } |
| 454 | 454 |
| --- src/tar.c | |
| +++ src/tar.c | |
| @@ -443,11 +443,11 @@ | |
| 443 | tar_begin(-1); |
| 444 | for(i=3; i<g.argc; i++){ |
| 445 | Blob file; |
| 446 | blob_zero(&file); |
| 447 | blob_read_from_file(&file, g.argv[i], eFType); |
| 448 | tar_add_file(g.argv[i], &file, file_perm(0,0), file_mtime(0,0)); |
| 449 | blob_reset(&file); |
| 450 | } |
| 451 | tar_finish(&zip); |
| 452 | blob_write_to_file(&zip, g.argv[2]); |
| 453 | } |
| 454 |
| --- src/tar.c | |
| +++ src/tar.c | |
| @@ -443,11 +443,11 @@ | |
| 443 | tar_begin(-1); |
| 444 | for(i=3; i<g.argc; i++){ |
| 445 | Blob file; |
| 446 | blob_zero(&file); |
| 447 | blob_read_from_file(&file, g.argv[i], eFType); |
| 448 | tar_add_file(g.argv[i], &file, file_perm(0,eFType), file_mtime(0,eFType)); |
| 449 | blob_reset(&file); |
| 450 | } |
| 451 | tar_finish(&zip); |
| 452 | blob_write_to_file(&zip, g.argv[2]); |
| 453 | } |
| 454 |
+15
-1
| --- src/timeline.c | ||
| +++ src/timeline.c | ||
| @@ -1877,11 +1877,25 @@ | ||
| 1877 | 1877 | " HAVING count(*)>1;\n" |
| 1878 | 1878 | "INSERT OR IGNORE INTO rnfork(rid)" |
| 1879 | 1879 | " SELECT cid FROM plink\n" |
| 1880 | 1880 | " WHERE (SELECT value FROM tagxref WHERE tagid=%d AND rid=cid)==" |
| 1881 | 1881 | " (SELECT value FROM tagxref WHERE tagid=%d AND rid=pid)\n" |
| 1882 | - " AND pid IN rnfork;", | |
| 1882 | + " GROUP BY cid" | |
| 1883 | + " HAVING count(*)>1;\n", | |
| 1884 | + TAG_BRANCH, TAG_BRANCH, TAG_BRANCH, TAG_BRANCH | |
| 1885 | + ); | |
| 1886 | + db_multi_exec( | |
| 1887 | + "INSERT OR IGNORE INTO rnfork(rid)\n" | |
| 1888 | + " SELECT cid FROM plink\n" | |
| 1889 | + " WHERE pid IN rnfork" | |
| 1890 | + " AND (SELECT value FROM tagxref WHERE tagid=%d AND rid=cid)==" | |
| 1891 | + " (SELECT value FROM tagxref WHERE tagid=%d AND rid=pid)\n" | |
| 1892 | + " UNION " | |
| 1893 | + " SELECT pid FROM plink\n" | |
| 1894 | + " WHERE cid IN rnfork" | |
| 1895 | + " AND (SELECT value FROM tagxref WHERE tagid=%d AND rid=cid)==" | |
| 1896 | + " (SELECT value FROM tagxref WHERE tagid=%d AND rid=pid)\n", | |
| 1883 | 1897 | TAG_BRANCH, TAG_BRANCH, TAG_BRANCH, TAG_BRANCH |
| 1884 | 1898 | ); |
| 1885 | 1899 | tmFlags |= TIMELINE_UNHIDE; |
| 1886 | 1900 | zType = "ci"; |
| 1887 | 1901 | disableY = 1; |
| 1888 | 1902 |
| --- src/timeline.c | |
| +++ src/timeline.c | |
| @@ -1877,11 +1877,25 @@ | |
| 1877 | " HAVING count(*)>1;\n" |
| 1878 | "INSERT OR IGNORE INTO rnfork(rid)" |
| 1879 | " SELECT cid FROM plink\n" |
| 1880 | " WHERE (SELECT value FROM tagxref WHERE tagid=%d AND rid=cid)==" |
| 1881 | " (SELECT value FROM tagxref WHERE tagid=%d AND rid=pid)\n" |
| 1882 | " AND pid IN rnfork;", |
| 1883 | TAG_BRANCH, TAG_BRANCH, TAG_BRANCH, TAG_BRANCH |
| 1884 | ); |
| 1885 | tmFlags |= TIMELINE_UNHIDE; |
| 1886 | zType = "ci"; |
| 1887 | disableY = 1; |
| 1888 |
| --- src/timeline.c | |
| +++ src/timeline.c | |
| @@ -1877,11 +1877,25 @@ | |
| 1877 | " HAVING count(*)>1;\n" |
| 1878 | "INSERT OR IGNORE INTO rnfork(rid)" |
| 1879 | " SELECT cid FROM plink\n" |
| 1880 | " WHERE (SELECT value FROM tagxref WHERE tagid=%d AND rid=cid)==" |
| 1881 | " (SELECT value FROM tagxref WHERE tagid=%d AND rid=pid)\n" |
| 1882 | " GROUP BY cid" |
| 1883 | " HAVING count(*)>1;\n", |
| 1884 | TAG_BRANCH, TAG_BRANCH, TAG_BRANCH, TAG_BRANCH |
| 1885 | ); |
| 1886 | db_multi_exec( |
| 1887 | "INSERT OR IGNORE INTO rnfork(rid)\n" |
| 1888 | " SELECT cid FROM plink\n" |
| 1889 | " WHERE pid IN rnfork" |
| 1890 | " AND (SELECT value FROM tagxref WHERE tagid=%d AND rid=cid)==" |
| 1891 | " (SELECT value FROM tagxref WHERE tagid=%d AND rid=pid)\n" |
| 1892 | " UNION " |
| 1893 | " SELECT pid FROM plink\n" |
| 1894 | " WHERE cid IN rnfork" |
| 1895 | " AND (SELECT value FROM tagxref WHERE tagid=%d AND rid=cid)==" |
| 1896 | " (SELECT value FROM tagxref WHERE tagid=%d AND rid=pid)\n", |
| 1897 | TAG_BRANCH, TAG_BRANCH, TAG_BRANCH, TAG_BRANCH |
| 1898 | ); |
| 1899 | tmFlags |= TIMELINE_UNHIDE; |
| 1900 | zType = "ci"; |
| 1901 | disableY = 1; |
| 1902 |
+1
-1
| --- src/zip.c | ||
| +++ src/zip.c | ||
| @@ -592,11 +592,11 @@ | ||
| 592 | 592 | } |
| 593 | 593 | zip_open(); |
| 594 | 594 | for(i=3; i<g.argc; i++){ |
| 595 | 595 | blob_zero(&file); |
| 596 | 596 | blob_read_from_file(&file, g.argv[i], eFType); |
| 597 | - zip_add_file(&sArchive, g.argv[i], &file, file_perm(0,0)); | |
| 597 | + zip_add_file(&sArchive, g.argv[i], &file, file_perm(0,eFType)); | |
| 598 | 598 | blob_reset(&file); |
| 599 | 599 | } |
| 600 | 600 | zip_close(&sArchive); |
| 601 | 601 | blob_write_to_file(&zip, g.argv[2]); |
| 602 | 602 | } |
| 603 | 603 |
| --- src/zip.c | |
| +++ src/zip.c | |
| @@ -592,11 +592,11 @@ | |
| 592 | } |
| 593 | zip_open(); |
| 594 | for(i=3; i<g.argc; i++){ |
| 595 | blob_zero(&file); |
| 596 | blob_read_from_file(&file, g.argv[i], eFType); |
| 597 | zip_add_file(&sArchive, g.argv[i], &file, file_perm(0,0)); |
| 598 | blob_reset(&file); |
| 599 | } |
| 600 | zip_close(&sArchive); |
| 601 | blob_write_to_file(&zip, g.argv[2]); |
| 602 | } |
| 603 |
| --- src/zip.c | |
| +++ src/zip.c | |
| @@ -592,11 +592,11 @@ | |
| 592 | } |
| 593 | zip_open(); |
| 594 | for(i=3; i<g.argc; i++){ |
| 595 | blob_zero(&file); |
| 596 | blob_read_from_file(&file, g.argv[i], eFType); |
| 597 | zip_add_file(&sArchive, g.argv[i], &file, file_perm(0,eFType)); |
| 598 | blob_reset(&file); |
| 599 | } |
| 600 | zip_close(&sArchive); |
| 601 | blob_write_to_file(&zip, g.argv[2]); |
| 602 | } |
| 603 |
+1
-1
| --- test/tester.tcl | ||
| +++ test/tester.tcl | ||
| @@ -391,11 +391,11 @@ | ||
| 391 | 391 | if {[info exists ::env(FOSSIL_TEST_DANGEROUS_IGNORE_OPEN_CHECKOUT)] && \ |
| 392 | 392 | $::env(FOSSIL_TEST_DANGEROUS_IGNORE_OPEN_CHECKOUT) eq "YES_DO_IT"} { |
| 393 | 393 | return |
| 394 | 394 | } |
| 395 | 395 | catch {exec $::fossilexe info} res |
| 396 | - if {![regexp {use --repository} $res]} { | |
| 396 | + if {[regexp {local-root:} $res]} { | |
| 397 | 397 | set projectName <unknown> |
| 398 | 398 | set localRoot <unknown> |
| 399 | 399 | regexp -line -- {^project-name: (.*)$} $res dummy projectName |
| 400 | 400 | set projectName [string trim $projectName] |
| 401 | 401 | regexp -line -- {^local-root: (.*)$} $res dummy localRoot |
| 402 | 402 |
| --- test/tester.tcl | |
| +++ test/tester.tcl | |
| @@ -391,11 +391,11 @@ | |
| 391 | if {[info exists ::env(FOSSIL_TEST_DANGEROUS_IGNORE_OPEN_CHECKOUT)] && \ |
| 392 | $::env(FOSSIL_TEST_DANGEROUS_IGNORE_OPEN_CHECKOUT) eq "YES_DO_IT"} { |
| 393 | return |
| 394 | } |
| 395 | catch {exec $::fossilexe info} res |
| 396 | if {![regexp {use --repository} $res]} { |
| 397 | set projectName <unknown> |
| 398 | set localRoot <unknown> |
| 399 | regexp -line -- {^project-name: (.*)$} $res dummy projectName |
| 400 | set projectName [string trim $projectName] |
| 401 | regexp -line -- {^local-root: (.*)$} $res dummy localRoot |
| 402 |
| --- test/tester.tcl | |
| +++ test/tester.tcl | |
| @@ -391,11 +391,11 @@ | |
| 391 | if {[info exists ::env(FOSSIL_TEST_DANGEROUS_IGNORE_OPEN_CHECKOUT)] && \ |
| 392 | $::env(FOSSIL_TEST_DANGEROUS_IGNORE_OPEN_CHECKOUT) eq "YES_DO_IT"} { |
| 393 | return |
| 394 | } |
| 395 | catch {exec $::fossilexe info} res |
| 396 | if {[regexp {local-root:} $res]} { |
| 397 | set projectName <unknown> |
| 398 | set localRoot <unknown> |
| 399 | regexp -line -- {^project-name: (.*)$} $res dummy projectName |
| 400 | set projectName [string trim $projectName] |
| 401 | regexp -line -- {^local-root: (.*)$} $res dummy localRoot |
| 402 |