Changeset 15341
- Timestamp:
- Oct 19, 2007, 3:27:00 PM (19 years ago)
- Location:
- trunk/ippTools
- Files:
-
- 2 edited
-
scripts/magictest.sh (modified) (1 diff)
-
src/magictool.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippTools/scripts/magictest.sh
r15340 r15341 10 10 magictool -addinputskyfile -magic_id 1 -diff_id 2 -node b || exit 1 11 11 magictool -inputtree -magic_id 1 -dep_file magic_dep.md 12 magictool -updaterun -state run -magic_id 1 || exit 1 13 12 14 magictool -addresult -magic_id 1 -node a -uri file:///foo/a 13 15 magictool -addresult -magic_id 1 -node b -uri file:///foo/b 14 16 magictool -addresult -magic_id 1 -node root -uri file:///foo/root 17 magictool -tomask 18 magictool -addmask -magic_id 1 -uri file:///foo/mask 15 19 16 magictool -updaterun -state run -magic_id 1 || exit 117 20 18 21 -
trunk/ippTools/src/magictool.c
r15340 r15341 655 655 { 656 656 PS_ASSERT_PTR_NON_NULL(config, false); 657 658 bool status = false; 659 psString magic_id = psMetadataLookupStr(&status, config->args, "-magic_id"); 660 if (!status) { 661 psError(PS_ERR_UNKNOWN, false, "failed to lookup value for -magic_id"); 662 return false; 663 } 664 if (!magic_id) { 665 psError(PS_ERR_UNKNOWN, true, "-magic_id is required"); 666 return false; 667 } 668 669 psString uri = psMetadataLookupStr(&status, config->args, "-uri"); 670 if (!status) { 671 psError(PS_ERR_UNKNOWN, false, "failed to lookup value for -uri"); 672 return false; 673 } 674 if (!uri) { 675 psError(PS_ERR_UNKNOWN, true, "-uri is required"); 676 return false; 677 } 678 679 if (!magicMaskInsert(config->dbh, 680 (psS64)atoll(magic_id), 681 uri 682 )) { 683 psError(PS_ERR_UNKNOWN, false, "database error"); 684 return false; 685 } 657 686 return true; 658 687 }
Note:
See TracChangeset
for help on using the changeset viewer.
