Fossil SCM

Ensure chars are signed when depending on the signedness.

preben 2024-01-03 14:43 trunk merge
Commit b7c7c2097f108c7b409cc5e2fc7b02e8d7ae1fea57f54de6f0a733016353256e
--- src/json_finfo.c
+++ src/json_finfo.c
@@ -36,11 +36,11 @@
3636
char const * zAfter = NULL;
3737
char const * zBefore = NULL;
3838
int limit = -1;
3939
int currentRow = 0;
4040
char const * zCheckin = NULL;
41
- char sort = -1;
41
+ signed char sort = -1;
4242
if(!g.perm.Read){
4343
json_set_err(FSL_JSON_E_DENIED,"Requires 'o' privileges.");
4444
return NULL;
4545
}
4646
json_warn( FSL_JSON_W_UNKNOWN, "Achtung: the output of the finfo command is up for change.");
4747
--- src/json_finfo.c
+++ src/json_finfo.c
@@ -36,11 +36,11 @@
36 char const * zAfter = NULL;
37 char const * zBefore = NULL;
38 int limit = -1;
39 int currentRow = 0;
40 char const * zCheckin = NULL;
41 char sort = -1;
42 if(!g.perm.Read){
43 json_set_err(FSL_JSON_E_DENIED,"Requires 'o' privileges.");
44 return NULL;
45 }
46 json_warn( FSL_JSON_W_UNKNOWN, "Achtung: the output of the finfo command is up for change.");
47
--- src/json_finfo.c
+++ src/json_finfo.c
@@ -36,11 +36,11 @@
36 char const * zAfter = NULL;
37 char const * zBefore = NULL;
38 int limit = -1;
39 int currentRow = 0;
40 char const * zCheckin = NULL;
41 signed char sort = -1;
42 if(!g.perm.Read){
43 json_set_err(FSL_JSON_E_DENIED,"Requires 'o' privileges.");
44 return NULL;
45 }
46 json_warn( FSL_JSON_W_UNKNOWN, "Achtung: the output of the finfo command is up for change.");
47
--- src/json_timeline.c
+++ src/json_timeline.c
@@ -143,12 +143,12 @@
143143
** property is set to the tag/branch name found in the request.
144144
**
145145
** Only one of "tag" or "branch" modes will work at a time, and if
146146
** both are specified, which one takes precedence is unspecified.
147147
*/
148
-static char json_timeline_add_tag_branch_clause(Blob *pSql,
149
- cson_object * pPayload){
148
+static signed char json_timeline_add_tag_branch_clause(Blob *pSql,
149
+ cson_object * pPayload){
150150
char const * zTag = NULL;
151151
char const * zBranch = NULL;
152152
char const * zMiOnly = NULL;
153153
char const * zUnhide = NULL;
154154
int tagid = 0;
@@ -220,11 +220,11 @@
220220
** applies one of them.
221221
**
222222
** Returns -1 if it adds a "before" clause, 1 if it adds
223223
** an "after" clause, and 0 if adds only an order-by clause.
224224
*/
225
-static char json_timeline_add_time_clause(Blob *pSql){
225
+static signed char json_timeline_add_time_clause(Blob *pSql){
226226
char const * zAfter = NULL;
227227
char const * zBefore = NULL;
228228
int rc = 0;
229229
zAfter = json_find_option_cstr("after",NULL,"a");
230230
zBefore = zAfter ? NULL : json_find_option_cstr("before",NULL,"b");
231231
--- src/json_timeline.c
+++ src/json_timeline.c
@@ -143,12 +143,12 @@
143 ** property is set to the tag/branch name found in the request.
144 **
145 ** Only one of "tag" or "branch" modes will work at a time, and if
146 ** both are specified, which one takes precedence is unspecified.
147 */
148 static char json_timeline_add_tag_branch_clause(Blob *pSql,
149 cson_object * pPayload){
150 char const * zTag = NULL;
151 char const * zBranch = NULL;
152 char const * zMiOnly = NULL;
153 char const * zUnhide = NULL;
154 int tagid = 0;
@@ -220,11 +220,11 @@
220 ** applies one of them.
221 **
222 ** Returns -1 if it adds a "before" clause, 1 if it adds
223 ** an "after" clause, and 0 if adds only an order-by clause.
224 */
225 static char json_timeline_add_time_clause(Blob *pSql){
226 char const * zAfter = NULL;
227 char const * zBefore = NULL;
228 int rc = 0;
229 zAfter = json_find_option_cstr("after",NULL,"a");
230 zBefore = zAfter ? NULL : json_find_option_cstr("before",NULL,"b");
231
--- src/json_timeline.c
+++ src/json_timeline.c
@@ -143,12 +143,12 @@
143 ** property is set to the tag/branch name found in the request.
144 **
145 ** Only one of "tag" or "branch" modes will work at a time, and if
146 ** both are specified, which one takes precedence is unspecified.
147 */
148 static signed char json_timeline_add_tag_branch_clause(Blob *pSql,
149 cson_object * pPayload){
150 char const * zTag = NULL;
151 char const * zBranch = NULL;
152 char const * zMiOnly = NULL;
153 char const * zUnhide = NULL;
154 int tagid = 0;
@@ -220,11 +220,11 @@
220 ** applies one of them.
221 **
222 ** Returns -1 if it adds a "before" clause, 1 if it adds
223 ** an "after" clause, and 0 if adds only an order-by clause.
224 */
225 static signed char json_timeline_add_time_clause(Blob *pSql){
226 char const * zAfter = NULL;
227 char const * zBefore = NULL;
228 int rc = 0;
229 zAfter = json_find_option_cstr("after",NULL,"a");
230 zBefore = zAfter ? NULL : json_find_option_cstr("before",NULL,"b");
231

Keyboard Shortcuts

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