summaryrefslogtreecommitdiff
path: root/sbin/fdisk/cmd.c
AgeCommit message (Expand)Author
2022-07-10Add some anti-feline input protection by refusing to processKenneth R Westerback
2022-07-10Use nice #define's for input buf size and output help buf size.Kenneth R Westerback
2022-05-09Replace a stray 0xA6 with DOSPTYP_OPENBSD. Tweak a ">= 2" to moreKenneth R Westerback
2022-05-06Rename PRT_uuid_to_[protection|typename] to PRT_uuid_to_[protected|sname],Kenneth R Westerback
2022-04-28Convert the internal GPT partition entries into host-endian formKenneth R Westerback
2022-04-24Use warnx() if errno is not relevant. close() after errno ofKenneth R Westerback
2022-04-20Simpify code manipulating GPT partition names by coalescingKenneth R Westerback
2022-04-20Eliminate some local pointers to gp[pn] and just use gp[pn].Kenneth R Westerback
2022-04-18Convert the GPT header read from disk into a host-endian version,Kenneth R Westerback
2022-03-16The 'status' parameter to uuid_* functions is uint32_t, not int.Kenneth R Westerback
2022-03-15Always use letoh32(gh.gh_part_num) instead of NGPTPARTITIONS whenKenneth R Westerback
2022-02-04%llu should be enough for anybody, no need to use %lld/(long long) forKenneth R Westerback
2022-02-04Remove CHS information from internal representation of MBR partitions. GenerateKenneth R Westerback
2022-01-27Nuke single use function PRT_fix_BN() and just use the ATA/ATAPI LBA -> CHSKenneth R Westerback
2022-01-22Wrap some long lines.Kenneth R Westerback
2022-01-21Split PRT_print() into PRT_print_parthdr() and PRT_print_part()Kenneth R Westerback
2021-10-21Remove 'disk' editing command. Determining the disk geometry on startup (fromKenneth R Westerback
2021-09-10Stop using NULL as a synonym for "s" (SECTORS). Just use "s".Kenneth R Westerback
2021-09-09Simplify logic in USER_edit() loop to eliminate unnecessaryKenneth R Westerback
2021-09-02Split part_type into separate types 'mbr_type' and 'gpt_type',Kenneth R Westerback
2021-09-01Improve editing GPT partition type GUID's by rejecting partitionKenneth R Westerback
2021-08-29Nuke unused variable and unnecessary initialization.Kenneth R Westerback
2021-08-28Add hex_octet() so the strtol(..,16) dance is done in just oneKenneth R Westerback
2021-08-24Trim leading/trailing whitespace from -e input to make commandKenneth R Westerback
2021-08-15Don't check & errx() after each and every invocation ofKenneth R Westerback
2021-08-12Further reduce cross-file confusion by adding USER_help() andKenneth R Westerback
2021-08-07Nuke a few Capt. Obvious comments.Kenneth R Westerback
2021-08-06Cleanup, clarify and generally polish the MBR/GPT initializationKenneth R Westerback
2021-07-21A couple of missed 'const'.Kenneth R Westerback
2021-07-21Use a dedicated struct mbr to hold the GPT protective MBR,Kenneth R Westerback
2021-07-19An MBR knows (mbr_lba_self) where it is supposed to go, noKenneth R Westerback
2021-07-17The first think MBR_init() does is memset(0) the gpt header and gptKenneth R Westerback
2021-07-17Nuke a bunch of Capt. Obvious or misleading comments.Kenneth R Westerback
2021-07-17Change edit/gedit/setpid/gsetpid to return 0/-1 to indicate success or failureKenneth R Westerback
2021-07-16Change PRT_protected_guid() to take native order uuid's instead of little endianKenneth R Westerback
2021-07-15No need for separate b_sectors, b_offset and b_type variables. We have structKenneth R Westerback
2021-07-13Disk sector addresses are normally stored/provided in uint64_tKenneth R Westerback
2021-07-12Toss 'const' in anywhere the compiler doesn't complain about, thus identifyingKenneth R Westerback
2021-07-12Final batch of struct field name tweaks. 'cmd_' for cmd, ut_' forKenneth R Westerback
2021-07-12Add 'dk_' prefix to struct disk field names.Kenneth R Westerback
2021-07-11Add 'prt_' prefix to struct prt field names.Kenneth R Westerback
2021-07-11Add 'mbr_' prefix to struct mbr field names.Kenneth R Westerback
2021-07-11Move ask_cmd(), ask_num(), ask_pid(), ask_string(), parse_b()Kenneth R Westerback
2021-07-11Add tabs to make variable declarations easierKenneth R Westerback
2021-07-11'return' is not a function call.Kenneth R Westerback
2021-06-28Add another epicycle to -A processing that ensures ONLY theKenneth R Westerback
2021-06-21Add -A option to "safely" initialize a GPT without removingKenneth R Westerback
2021-06-16Ensure that the '-i' command line option and the 'reinit [mbr]'Kenneth R Westerback
2021-06-14Only use of 'reinited' died in cmd.c r1.100. It is now set in aKenneth R Westerback
2021-06-13Have gedit() and gsetpid() both return CMD_CLEAN if no data hasKenneth R Westerback