mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-06-21 13:08:42 +00:00
snprintf: Remove the %o and %p support
%x could be used to replace the %o print option. %x could be used to replace the %p print option also. Tracked-On: #1656 Signed-off-by: Yin Fengwei <fengwei.yin@intel.com> Acked-by: Eddie Dong <eddie.dong@intel.com>
This commit is contained in:
parent
6150c0611f
commit
1b1338bc04
@ -508,19 +508,6 @@ void do_print(const char *fmt_arg, struct print_param *param,
|
|||||||
uint32_t));
|
uint32_t));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/* octal number */
|
|
||||||
else if (ch == 'o') {
|
|
||||||
if ((param->vars.flags &
|
|
||||||
PRINT_FLAG_LONG_LONG) != 0U) {
|
|
||||||
print_pow2(param,
|
|
||||||
__builtin_va_arg(args,
|
|
||||||
uint64_t), 3U);
|
|
||||||
} else {
|
|
||||||
print_pow2(param,
|
|
||||||
__builtin_va_arg(args,
|
|
||||||
uint32_t), 3U);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/* hexadecimal number */
|
/* hexadecimal number */
|
||||||
else if ((ch == 'X') || (ch == 'x')) {
|
else if ((ch == 'X') || (ch == 'x')) {
|
||||||
if (ch == 'X') {
|
if (ch == 'X') {
|
||||||
@ -546,12 +533,6 @@ void do_print(const char *fmt_arg, struct print_param *param,
|
|||||||
}
|
}
|
||||||
print_string(param, s);
|
print_string(param, s);
|
||||||
}
|
}
|
||||||
/* pointer argument */
|
|
||||||
else if (ch == 'p') {
|
|
||||||
param->vars.flags |= PRINT_FLAG_ALTERNATE_FORM;
|
|
||||||
print_pow2(param, (uint64_t)
|
|
||||||
__builtin_va_arg(args, void *), 4U);
|
|
||||||
}
|
|
||||||
/* single character argument */
|
/* single character argument */
|
||||||
else if (ch == 'c') {
|
else if (ch == 'c') {
|
||||||
char c[2];
|
char c[2];
|
||||||
|
Loading…
Reference in New Issue
Block a user