Changeset 68b5dd11 in mainline for uspace/app/fdisk/fdisk.c
- Timestamp:
- 2015-10-20T10:08:15Z (9 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- b598460a
- Parents:
- 44fe800
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/app/fdisk/fdisk.c
r44fe800 r68b5dd11 137 137 scap = NULL; 138 138 139 rc = nchoice_add(choice, dtext, info );139 rc = nchoice_add(choice, dtext, info, 0); 140 140 if (rc != EOK) { 141 141 assert(rc == ENOMEM); … … 156 156 } 157 157 158 rc = nchoice_add(choice, "Exit", NULL );158 rc = nchoice_add(choice, "Exit", NULL, 0); 159 159 if (rc != EOK) { 160 160 assert(rc == ENOMEM); … … 219 219 goto error; 220 220 221 rc = nchoice_add(choice, sltype, (void *)(uintptr_t)i); 221 rc = nchoice_add(choice, sltype, (void *)(uintptr_t)i, 222 i == LT_DEFAULT); 222 223 if (rc != EOK) { 223 224 assert(rc == ENOMEM); … … 304 305 goto error; 305 306 306 rc = nchoice_add(choice, sfstype, (void *)(uintptr_t)i); 307 rc = nchoice_add(choice, sfstype, (void *)(uintptr_t)i, 308 i == VOL_FSTYPE_DEFAULT); 307 309 if (rc != EOK) { 308 310 assert(rc == ENOMEM); … … 439 441 } 440 442 441 rc = nchoice_add(choice, sdesc, (void *)part );443 rc = nchoice_add(choice, sdesc, (void *)part, 0); 442 444 if (rc != EOK) { 443 445 assert(rc == ENOMEM); … … 634 636 rc = nchoice_add(choice, "Create primary " 635 637 "partition", 636 (void *)devac_create_pri_part );638 (void *)devac_create_pri_part, 0); 637 639 if (rc != EOK) { 638 640 assert(rc == ENOMEM); … … 645 647 rc = nchoice_add(choice, "Create extended " 646 648 "partition", 647 (void *)devac_create_ext_part );649 (void *)devac_create_ext_part, 0); 648 650 if (rc != EOK) { 649 651 assert(rc == ENOMEM); … … 656 658 rc = nchoice_add(choice, "Create logical " 657 659 "partition", 658 (void *)devac_create_log_part );660 (void *)devac_create_log_part, 0); 659 661 if (rc != EOK) { 660 662 assert(rc == ENOMEM); … … 666 668 if ((linfo.flags & lf_can_create_pri) != 0) { 667 669 rc = nchoice_add(choice, "Create partition", 668 (void *)devac_create_pri_part );670 (void *)devac_create_pri_part, 0); 669 671 if (rc != EOK) { 670 672 assert(rc == ENOMEM); … … 677 679 if ((linfo.flags & lf_can_delete_part) != 0) { 678 680 rc = nchoice_add(choice, "Delete partition", 679 (void *)devac_delete_part );681 (void *)devac_delete_part, 0); 680 682 if (rc != EOK) { 681 683 assert(rc == ENOMEM); … … 687 689 if ((dflags & fdf_can_create_label) != 0) { 688 690 rc = nchoice_add(choice, "Create label", 689 (void *)devac_create_label );691 (void *)devac_create_label, 0); 690 692 if (rc != EOK) { 691 693 assert(rc == ENOMEM); … … 697 699 if ((dflags & fdf_can_delete_label) != 0) { 698 700 rc = nchoice_add(choice, "Delete label", 699 (void *)devac_delete_label );701 (void *)devac_delete_label, 0); 700 702 if (rc != EOK) { 701 703 assert(rc == ENOMEM); … … 707 709 if ((dflags & fdf_can_erase_dev) != 0) { 708 710 rc = nchoice_add(choice, "Erase disk", 709 (void *)devac_erase_disk );710 if (rc != EOK) { 711 assert(rc == ENOMEM); 712 printf("Out of memory.\n"); 713 goto error; 714 } 715 } 716 717 rc = nchoice_add(choice, "Exit", (void *)devac_exit );711 (void *)devac_erase_disk, 0); 712 if (rc != EOK) { 713 assert(rc == ENOMEM); 714 printf("Out of memory.\n"); 715 goto error; 716 } 717 } 718 719 rc = nchoice_add(choice, "Exit", (void *)devac_exit, 0); 718 720 if (rc != EOK) { 719 721 assert(rc == ENOMEM);
Note:
See TracChangeset
for help on using the changeset viewer.