mirror of
https://github.com/RGBCube/serenity
synced 2025-05-17 21:25:07 +00:00
UserspaceEmulator: Replace printf usages with format.
This replaces almost all usages. Some have to remain because 'outf' always appends a newline. (It inherits this behaviour from LogStream.)
This commit is contained in:
parent
fb7a94c959
commit
ba3488a6d5
6 changed files with 67 additions and 69 deletions
|
@ -68,7 +68,7 @@ MmapRegion::~MmapRegion()
|
|||
ValueWithShadow<u8> MmapRegion::read8(FlatPtr offset)
|
||||
{
|
||||
if (!is_readable()) {
|
||||
warn() << "8-bit read from unreadable MmapRegion @ " << (const void*)(base() + offset);
|
||||
warnf("8-bit read from unreadable MmapRegion @ {:p}", base() + offset);
|
||||
Emulator::the().dump_backtrace();
|
||||
TODO();
|
||||
}
|
||||
|
@ -85,7 +85,7 @@ ValueWithShadow<u8> MmapRegion::read8(FlatPtr offset)
|
|||
ValueWithShadow<u16> MmapRegion::read16(u32 offset)
|
||||
{
|
||||
if (!is_readable()) {
|
||||
warn() << "16-bit from unreadable MmapRegion @ " << (const void*)(base() + offset);
|
||||
warnf("16-bit read from unreadable MmapRegion @ {:p}", base() + offset);
|
||||
Emulator::the().dump_backtrace();
|
||||
TODO();
|
||||
}
|
||||
|
@ -102,7 +102,7 @@ ValueWithShadow<u16> MmapRegion::read16(u32 offset)
|
|||
ValueWithShadow<u32> MmapRegion::read32(u32 offset)
|
||||
{
|
||||
if (!is_readable()) {
|
||||
warn() << "32-bit read from unreadable MmapRegion @ " << (const void*)(base() + offset);
|
||||
warnf("32-bit read from unreadable MmapRegion @ {:p}", base() + offset);
|
||||
Emulator::the().dump_backtrace();
|
||||
TODO();
|
||||
}
|
||||
|
@ -119,7 +119,7 @@ ValueWithShadow<u32> MmapRegion::read32(u32 offset)
|
|||
ValueWithShadow<u64> MmapRegion::read64(u32 offset)
|
||||
{
|
||||
if (!is_readable()) {
|
||||
warn() << "64-bit read from unreadable MmapRegion @ " << (const void*)(base() + offset);
|
||||
warnf("64-bit read from unreadable MmapRegion @ {:p}", base() + offset);
|
||||
Emulator::the().dump_backtrace();
|
||||
TODO();
|
||||
}
|
||||
|
@ -136,7 +136,7 @@ ValueWithShadow<u64> MmapRegion::read64(u32 offset)
|
|||
void MmapRegion::write8(u32 offset, ValueWithShadow<u8> value)
|
||||
{
|
||||
if (!is_writable()) {
|
||||
warn() << "8-bit write to unreadable MmapRegion @ " << (const void*)(base() + offset);
|
||||
warnf("8-bit write from unwritable MmapRegion @ {:p}", base() + offset);
|
||||
Emulator::the().dump_backtrace();
|
||||
TODO();
|
||||
}
|
||||
|
@ -154,7 +154,7 @@ void MmapRegion::write8(u32 offset, ValueWithShadow<u8> value)
|
|||
void MmapRegion::write16(u32 offset, ValueWithShadow<u16> value)
|
||||
{
|
||||
if (!is_writable()) {
|
||||
warn() << "16-bit write to unreadable MmapRegion @ " << (const void*)(base() + offset);
|
||||
warnf("16-bit write from unwritable MmapRegion @ {:p}", base() + offset);
|
||||
Emulator::the().dump_backtrace();
|
||||
TODO();
|
||||
}
|
||||
|
@ -172,7 +172,7 @@ void MmapRegion::write16(u32 offset, ValueWithShadow<u16> value)
|
|||
void MmapRegion::write32(u32 offset, ValueWithShadow<u32> value)
|
||||
{
|
||||
if (!is_writable()) {
|
||||
warn() << "32-bit write to unreadable MmapRegion @ " << (const void*)(base() + offset);
|
||||
warnf("32-bit write from unwritable MmapRegion @ {:p}", base() + offset);
|
||||
Emulator::the().dump_backtrace();
|
||||
TODO();
|
||||
}
|
||||
|
@ -191,7 +191,7 @@ void MmapRegion::write32(u32 offset, ValueWithShadow<u32> value)
|
|||
void MmapRegion::write64(u32 offset, ValueWithShadow<u64> value)
|
||||
{
|
||||
if (!is_writable()) {
|
||||
warn() << "64-bit write to unreadable MmapRegion @ " << (const void*)(base() + offset);
|
||||
warnf("64-bit write from unwritable MmapRegion @ {:p}", base() + offset);
|
||||
Emulator::the().dump_backtrace();
|
||||
TODO();
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue