Fossil SCM

Remove unused variables

andygoth 2016-05-17 04:16 trunk
Commit f9decff05e419d24144dde03c8518c87c3a070a6
1 file changed -3
--- src/export.c
+++ src/export.c
@@ -185,11 +185,10 @@
185185
** database. Otherwise, 0 is returned.
186186
** mark->name is dynamically allocated, and owned by the caller.
187187
*/
188188
int parse_mark(char *line, struct mark_t *mark){
189189
char *cur_tok;
190
- char type;
191190
cur_tok = strtok(line, " \t");
192191
if(!cur_tok||strlen(cur_tok)<2){
193192
return -1;
194193
}
195194
mark->rid = atoi(&cur_tok[1]);
@@ -243,11 +242,10 @@
243242
** or the rid/uuid information doesn't match what is in the repository
244243
** database. Otherwise, 0 is returned.
245244
*/
246245
int import_marks(FILE* f, Bag *blobs, Bag *vers){
247246
char line[101];
248
- size_t len;
249247
while(fgets(line, sizeof(line), f)){
250248
struct mark_t mark;
251249
if(strlen(line)==100&&line[99]!='\n'){
252250
/* line too long */
253251
return -1;
@@ -357,11 +355,10 @@
357355
db_multi_exec("CREATE TEMPORARY TABLE oldblob(rid INTEGER PRIMARY KEY)");
358356
db_multi_exec("CREATE TEMPORARY TABLE oldcommit(rid INTEGER PRIMARY KEY)");
359357
db_multi_exec("CREATE TEMP TABLE xmark(tname TEXT UNIQUE, trid INT, tuuid TEXT)");
360358
if( markfile_in!=0 ){
361359
Stmt qb,qc;
362
- char line[100];
363360
FILE *f;
364361
int rid;
365362
366363
f = fossil_fopen(markfile_in, "r");
367364
if( f==0 ){
368365
--- src/export.c
+++ src/export.c
@@ -185,11 +185,10 @@
185 ** database. Otherwise, 0 is returned.
186 ** mark->name is dynamically allocated, and owned by the caller.
187 */
188 int parse_mark(char *line, struct mark_t *mark){
189 char *cur_tok;
190 char type;
191 cur_tok = strtok(line, " \t");
192 if(!cur_tok||strlen(cur_tok)<2){
193 return -1;
194 }
195 mark->rid = atoi(&cur_tok[1]);
@@ -243,11 +242,10 @@
243 ** or the rid/uuid information doesn't match what is in the repository
244 ** database. Otherwise, 0 is returned.
245 */
246 int import_marks(FILE* f, Bag *blobs, Bag *vers){
247 char line[101];
248 size_t len;
249 while(fgets(line, sizeof(line), f)){
250 struct mark_t mark;
251 if(strlen(line)==100&&line[99]!='\n'){
252 /* line too long */
253 return -1;
@@ -357,11 +355,10 @@
357 db_multi_exec("CREATE TEMPORARY TABLE oldblob(rid INTEGER PRIMARY KEY)");
358 db_multi_exec("CREATE TEMPORARY TABLE oldcommit(rid INTEGER PRIMARY KEY)");
359 db_multi_exec("CREATE TEMP TABLE xmark(tname TEXT UNIQUE, trid INT, tuuid TEXT)");
360 if( markfile_in!=0 ){
361 Stmt qb,qc;
362 char line[100];
363 FILE *f;
364 int rid;
365
366 f = fossil_fopen(markfile_in, "r");
367 if( f==0 ){
368
--- src/export.c
+++ src/export.c
@@ -185,11 +185,10 @@
185 ** database. Otherwise, 0 is returned.
186 ** mark->name is dynamically allocated, and owned by the caller.
187 */
188 int parse_mark(char *line, struct mark_t *mark){
189 char *cur_tok;
 
190 cur_tok = strtok(line, " \t");
191 if(!cur_tok||strlen(cur_tok)<2){
192 return -1;
193 }
194 mark->rid = atoi(&cur_tok[1]);
@@ -243,11 +242,10 @@
242 ** or the rid/uuid information doesn't match what is in the repository
243 ** database. Otherwise, 0 is returned.
244 */
245 int import_marks(FILE* f, Bag *blobs, Bag *vers){
246 char line[101];
 
247 while(fgets(line, sizeof(line), f)){
248 struct mark_t mark;
249 if(strlen(line)==100&&line[99]!='\n'){
250 /* line too long */
251 return -1;
@@ -357,11 +355,10 @@
355 db_multi_exec("CREATE TEMPORARY TABLE oldblob(rid INTEGER PRIMARY KEY)");
356 db_multi_exec("CREATE TEMPORARY TABLE oldcommit(rid INTEGER PRIMARY KEY)");
357 db_multi_exec("CREATE TEMP TABLE xmark(tname TEXT UNIQUE, trid INT, tuuid TEXT)");
358 if( markfile_in!=0 ){
359 Stmt qb,qc;
 
360 FILE *f;
361 int rid;
362
363 f = fossil_fopen(markfile_in, "r");
364 if( f==0 ){
365

Keyboard Shortcuts

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