| 643 | } |
| 644 | |
| 645 | static int |
| 646 | parse_dir_onfail(char **conf) |
| 647 | { |
| 648 | char *action; |
| 649 | int error; |
| 650 | |
| 651 | error = parse_token(conf, &action); |
| 652 | if (error) |
| 653 | return (error); |
| 654 | |
| 655 | if (!strcmp(action, "continue")) |
| 656 | root_mount_onfail = A_CONTINUE; |
| 657 | else if (!strcmp(action, "panic")) |
| 658 | root_mount_onfail = A_PANIC; |
| 659 | else if (!strcmp(action, "reboot")) |
| 660 | root_mount_onfail = A_REBOOT; |
| 661 | else if (!strcmp(action, "retry")) |
| 662 | root_mount_onfail = A_RETRY; |
| 663 | else { |
| 664 | printf("rootmount: %s: unknown action\n", action); |
| 665 | error = EINVAL; |
| 666 | } |
| 667 | |
| 668 | free(action, M_TEMP); |
| 669 | return (0); |
| 670 | } |
| 671 | |
| 672 | static int |
| 673 | parse_dir_timeout(char **conf) |
no test coverage detected