Constify the first argument to expand_number() so that it can
be called with a const without the compiler grisling.
This commit is contained in:
parent
78a5dd56cd
commit
26fc37307b
@ -37,7 +37,7 @@
|
||||
.In libutil.h
|
||||
.Ft int
|
||||
.Fo expand_number
|
||||
.Fa "char *buf" "int64_t *num"
|
||||
.Fa "const char *buf" "int64_t *num"
|
||||
.Fc
|
||||
.Sh DESCRIPTION
|
||||
The
|
||||
|
@ -46,7 +46,7 @@ __FBSDID("$FreeBSD$");
|
||||
* 8) A positive decimal number followed by a 'e' or 'E' (mult by 1 << 60).
|
||||
*/
|
||||
int
|
||||
expand_number(char *buf, int64_t *num)
|
||||
expand_number(const char *buf, int64_t *num)
|
||||
{
|
||||
static const char unit[] = "bkmgtpe";
|
||||
char *endptr, s;
|
||||
|
@ -82,7 +82,7 @@ int forkpty(int *_amaster, char *_name,
|
||||
struct termios *_termp, struct winsize *_winp);
|
||||
int humanize_number(char *_buf, size_t _len, int64_t _number,
|
||||
const char *_suffix, int _scale, int _flags);
|
||||
int expand_number(char *_buf, int64_t *_num);
|
||||
int expand_number(const char *_buf, int64_t *_num);
|
||||
const char *uu_lockerr(int _uu_lockresult);
|
||||
int uu_lock(const char *_ttyname);
|
||||
int uu_unlock(const char *_ttyname);
|
||||
|
Loading…
x
Reference in New Issue
Block a user