fdisk: fix a case where we can inadvertently close /proc/partitions fd early

This commit is contained in:
Denis Vlasenko
2008-04-17 01:52:28 +00:00
parent 4437d19fb4
commit c033d5196d
2 changed files with 29 additions and 19 deletions

View File

@@ -414,7 +414,7 @@ bsd_select(void)
break;
case 'q':
if (ENABLE_FEATURE_CLEAN_UP)
close(dev_fd);
close_dev_fd();
exit(EXIT_SUCCESS);
case 'r':
return;