#
4a47b700 |
| 01-Feb-2016 |
krw <krw@openbsd.org> |
Use printf("%s",prompt) rather than printf(prompt) just for paranoia's sake.
|
#
a63f2390 |
| 30-Jan-2016 |
krw <krw@openbsd.org> |
Move last three lines (#define's) from dpme.h to partition_map.h and tweak #include's as necessary.
|
#
32401e4b |
| 29-Jan-2016 |
krw <krw@openbsd.org> |
Base 10 should be enough for anybody! Allowing hex and octal number input for partition id's, partition starting points and partition sizes is silly, especially since we never display anything but b
Base 10 should be enough for anybody! Allowing hex and octal number input for partition id's, partition starting points and partition sizes is silly, especially since we never display anything but base 10 numbers.
Also ensure that numbers end with a space, tab or newline.
show more ...
|
#
106ae2cb |
| 28-Jan-2016 |
krw <krw@openbsd.org> |
Use consistent 'return' idiom -- no parenthesis since that was the style of the existing code.
|
#
f4081a22 |
| 27-Jan-2016 |
krw <krw@openbsd.org> |
On-disk partition name/types/processorid may or may not be NUL terminated after all. So add an extra byte for a NUL in the in-memory struct's.
|
#
5046737f |
| 27-Jan-2016 |
krw <krw@openbsd.org> |
Nope. Missed a couple of '{}' that could go.
|
#
bd45c0ec |
| 27-Jan-2016 |
krw <krw@openbsd.org> |
Nuke another (and I hope final) batch of superfluous '{}' around single statements.
|
#
8799a2d3 |
| 26-Jan-2016 |
krw <krw@openbsd.org> |
Rework and simplify string argument parsing. All string arguments are at most DPISTRLEN (32) characters so there is no need for fancy dynamic growing strings. Use a DPISTRLEN long buffer and bail if
Rework and simplify string argument parsing. All string arguments are at most DPISTRLEN (32) characters so there is no need for fancy dynamic growing strings. Use a DPISTRLEN long buffer and bail if it fills up.
Rename get_string() to get_dpistr() and get_string_argument() to get_dpstr_argument() to emphasize they will return strings that fit in DPISTRLEN.
Rework & simplify a pair of their consumers - do_rename_partition() and do_change_type() - to be more obviously identitical to each other bar the displayed verbiage.
show more ...
|
#
a8b53b4c |
| 26-Jan-2016 |
krw <krw@openbsd.org> |
Whitespace, line wrapping fixes. Nuke many superfluous '{}' around single statements. 0 -> NULL for pointer checks.
|
#
8887dc3d |
| 24-Jan-2016 |
krw <krw@openbsd.org> |
Whitespace fixes.
|
#
67ac1252 |
| 23-Jan-2016 |
krw <krw@openbsd.org> |
No need for 'default_value' parameter for get_number_argument() since we always pass kDefault. a.k.a. -1. Nuke kDefault since it is now unused.
Nuke unused #define MAXIOSIZE in passing.
|
#
066001bd |
| 23-Jan-2016 |
krw <krw@openbsd.org> |
No need for get_string_argument() parameter 'reprompt' since we always pass it '1'.
|
#
36bbc7f2 |
| 21-Jan-2016 |
krw <krw@openbsd.org> |
Hoist all file opening and ioctl calls into main(), passing a pointer to a valid map to edit(). Should enable pledging a la fdisk at some point.
Since edit() always gets a valid map (and maintains i
Hoist all file opening and ioctl calls into main(), passing a pointer to a valid map to edit(). Should enable pledging a la fdisk at some point.
Since edit() always gets a valid map (and maintains its validity even when 'I'nitializing a new one) many checks for (map == NULL) are junked.
Remove some dances around block sizes by using DEV_BSIZE everywhere since we don't support non-DEV_BSIZE (a.k.a. 512-byte) sectors.
Remove many superfluous #include statements.
show more ...
|
#
f28a080d |
| 19-Jan-2016 |
krw <krw@openbsd.org> |
Remove unused global 'io_buffer'.
|
#
928e0d77 |
| 18-Jan-2016 |
krw <krw@openbsd.org> |
Run indent(1) over it and tweak the results a bit manually to look more KNF'ish.
|
#
86ec409a |
| 17-Jan-2016 |
krw <krw@openbsd.org> |
Change "//" comments to "/**/". Nuke really stupid ones.
|
#
f947f9cb |
| 17-Jan-2016 |
krw <krw@openbsd.org> |
Reduce namespace pollution by eliminating parameter names from forward declarations.
|
#
8a7428d7 |
| 17-Jan-2016 |
krw <krw@openbsd.org> |
Kill leading, imbedded, trailing whitespace.
|
#
78070bdd |
| 17-Jan-2016 |
krw <krw@openbsd.org> |
Remove a bunch of ridiculous and uninformative comments like "// Defines".
|
#
61fb02b0 |
| 12-Jan-2016 |
krw <krw@openbsd.org> |
#define LOFF_T off_t #define llseek lseek #define LOFF_T_MAX LLONG_MAX
I mean, really? Nuke'em and use off_t, lseek and LLONG_MAX.
Also make a couple of checks for overflow of off_t value more like
#define LOFF_T off_t #define llseek lseek #define LOFF_T_MAX LLONG_MAX
I mean, really? Nuke'em and use off_t, lseek and LLONG_MAX.
Also make a couple of checks for overflow of off_t value more likely to work.
ok millert@
show more ...
|
#
68d0f91b |
| 12-Jan-2016 |
krw <krw@openbsd.org> |
Use normal err/errx/warn/warnx rather than handrolling new ones. Move usage() to pdisk.c and nuke do_help() and '-h'.
ok jasper@ deraadt@
|
#
77f5c868 |
| 11-Jan-2016 |
jasper <jasper@openbsd.org> |
trailing whitespace
|
#
fb04e59a |
| 11-Jan-2016 |
jasper <jasper@openbsd.org> |
add rcs ids
|
#
5ae94ef8 |
| 20-Aug-2015 |
deraadt <deraadt@openbsd.org> |
<stdlib.h> is included, so do not need to cast result from malloc, calloc, realloc* ok krw millert
|
#
5a053c2d |
| 11-May-2006 |
martin <martin@openbsd.org> |
remove a bunch of linux and NeXT defines and, in turn, -D__unix__
|