- if (!player->argp[1] || !*player->argp[1]) {
- if (unit_type == EF_BAD) {
- str = getstring("(sects)? ", buf);
- } else {
- sprintf(prompt, "(sects, %s)? ", ef_nameof(unit_type));
- str = getstring(prompt, buf);
- }
-
- if (!str || !*str)
- return RET_SYN;
- } else
- str = player->argp[1];
+ if (unit_type == EF_BAD)
+ prompt = "(sects)? ";
+ else {
+ sprintf(prompt_buf, "(sects, %s)? ", ef_nameof(unit_type));
+ prompt = prompt_buf;
+ }
+ str = getstarg(player->argp[1], prompt, buf);
+ if (!str || !*str)
+ return RET_SYN;