374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
|
/* We should be done with options.. */
verify_all_options();
if( g.argc!=6 ){
usage("PIVOT V1 V2 MERGED");
}
if( blob_read_from_file(&pivot, g.argv[2])<0 ){
fossil_fatal("cannot read %s\n", g.argv[2]);
}
if( blob_read_from_file(&v1, g.argv[3])<0 ){
fossil_fatal("cannot read %s\n", g.argv[3]);
}
if( blob_read_from_file(&v2, g.argv[4])<0 ){
fossil_fatal("cannot read %s\n", g.argv[4]);
}
blob_merge(&pivot, &v1, &v2, &merged);
if( blob_write_to_file(&merged, g.argv[5])<blob_size(&merged) ){
fossil_fatal("cannot write %s\n", g.argv[4]);
}
blob_reset(&pivot);
blob_reset(&v1);
blob_reset(&v2);
blob_reset(&merged);
}
|
|
|
|
|
|
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
|
/* We should be done with options.. */
verify_all_options();
if( g.argc!=6 ){
usage("PIVOT V1 V2 MERGED");
}
if( blob_read_from_file(&pivot, g.argv[2])<0 ){
fossil_fatal("cannot read %s", g.argv[2]);
}
if( blob_read_from_file(&v1, g.argv[3])<0 ){
fossil_fatal("cannot read %s", g.argv[3]);
}
if( blob_read_from_file(&v2, g.argv[4])<0 ){
fossil_fatal("cannot read %s", g.argv[4]);
}
blob_merge(&pivot, &v1, &v2, &merged);
if( blob_write_to_file(&merged, g.argv[5])<blob_size(&merged) ){
fossil_fatal("cannot write %s", g.argv[4]);
}
blob_reset(&pivot);
blob_reset(&v1);
blob_reset(&v2);
blob_reset(&merged);
}
|