summaryrefslogtreecommitdiffstats
path: root/sbin/fdisk/cmd.c
AgeCommit message (Expand)AuthorFilesLines
2017-11-13Constrain MBR partition offsets to 0 .. disk.size - 1.krw1-2/+2
2016-09-03'reinit' should check the MBR on disk, as the man page says.krw1-2/+2
2016-08-02capitalize a question like all the othersjcs1-2/+2
2016-03-30Dump strdup()/free() dance and just use a local buffer to translate helpkrw1-9/+7
2016-03-28The GPT versions of help strings that don't contain'MBR' werekrw1-9/+7
2016-01-09Revamp the display of GPT information, hiding less importantkrw1-5/+5
2015-11-26When prompting for a GPT partition type, use the partition's current type astim1-2/+3
2015-11-25Try harder to prevent 0-length partitions from being defined.krw1-9/+10
2015-11-21Bring GPT partition editing into line with MBR partition editingkrw1-8/+7
2015-11-21Nuke long standing annoyance of EDIT() macros and switch both Xedit()krw1-50/+57
2015-11-19When an existing partition is modified in LBA mode, ensure that the partitiontim1-7/+12
2015-11-19Reduce overburden of unnecessary #include's. Note that param.h iskrw1-7/+5
2015-11-18Change #include <memory.h> to #include <string.h>krw1-2/+2
2015-11-13Move from opening/closing disk for every i/o to opening the disk oncekrw1-14/+5
2015-11-03Don't allow the user to enter GPT partition names too large to fitkrw1-1/+7
2015-10-26Add GPT editing. Based on GSOC 2014 work by Markus Muller.krw1-31/+199
2015-04-02Don't printf("offset: ...) before every call to MBR_print(). Do itkrw1-3/+1
2015-03-26Adapt ask_string() from disklabel's getstring(). It will be usedkrw1-3/+3
2015-03-26Expand internal representation of partition starting LBA and sizekrw1-8/+8
2015-03-19When zapping the GPT at the end of the disk, don't use disk.sizekrw1-2/+2
2015-03-18Stop passing around little used 'struct mbr tt' parameter. Justkrw1-21/+20
2015-03-17Stop passing around little used and superfluous 'offset' parameter.krw1-21/+21
2015-03-16Stop passing around a pointer to the stack variable 'disk' in main().krw1-57/+42
2015-03-14Whitespace & KNF tweaks. Change functions whose return values arekrw1-14/+11
2015-03-14Switch all the license blocks to the standard OpenBSD/ISC license.krw1-20/+11
2015-02-10If 'write' is issued after a 'reinit' command, and the MBR to bekrw1-2/+10
2015-02-09Rename 'm_flag' to 'e_flag' since it's '-e' that sets it. Renamekrw1-2/+2
2014-03-31Use return value constants to make effects clearer than the usekrw1-18/+12
2014-03-31Whitespace rectification.krw1-4/+1
2014-03-20Add back various #includes of err.h, unistd.h, ctype.h, ioctl.h tokrw1-1/+4
2014-03-17Nuke pointless blank lines, defines, comments and casts. Eliminatekrw1-10/+12
2014-03-17Un-revert, being careful to not break snap building. Add paranoia checkkrw1-16/+15
2014-03-14Revert last -- broke building snaps.krw1-15/+16
2014-03-13Remove some lint -- ARGSUSED.krw1-15/+1
2014-03-13Merge 'struct DISK_metrics' and 'struct disk' into one, since we don'tkrw1-16/+15
2014-03-10No need to pass the name of the command to the function that iskrw1-31/+29
2014-03-09Instead of passing around 'char buf[DEV_BSIZE]' buffers, pass aroundkrw1-16/+10
2014-03-07Relieve the code of an overburden of unnecessary typedefkrw1-25/+35
2013-03-21more substantial include cleanupderaadt1-3/+4
2013-03-21I don't feel great about adding an include for <sys/param.h>, but I feelderaadt1-2/+1
2012-07-11Simplify guts and calling of getuint(). Eliminate a useless 'help'krw1-27/+5
2012-07-09We always want to do unit conversions. So flags parameter of getuint()krw1-3/+3
2012-07-09I want some of what kjell was smoking 10 years ago when he addedkrw1-6/+3
2012-07-09Make 'swap' command work like fdisk(8) says -- you must supply two validkrw1-5/+17
2012-07-09Use strtonum() instead of strtol() inside ask_num(). Many overflowskrw1-6/+2
2012-07-08set_pid() does not need prompt string, low or high parameters. Thesekrw1-2/+2
2012-07-08Split out an ask_pid() function rather than over-parameterizing thekrw1-12/+10
2012-07-08Call Xsetpid() to edit the partition type from Xedit() rather thankrw1-20/+14
2012-07-08Nuke useless EDIT() #define in Xsetpid.krw1-9/+8
2012-07-08Replace tricker atoi() and hand rolled parsing with strsep() andkrw1-13/+15