mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-12-28 21:54:40 +03:00
AK: Make dbgprintf() and dbgputstr() go to stderr on non-Serenity hosts
This commit is contained in:
parent
0d48fb9a87
commit
20e58c5513
Notes:
sideshowbarker
2024-07-19 07:52:07 +09:00
Author: https://github.com/awesomekling Commit: https://github.com/SerenityOS/serenity/commit/20e58c5513f
@ -45,6 +45,6 @@ inline int dbgputstr(const char (&array)[N])
|
||||
#else
|
||||
# include <stdio.h>
|
||||
# define kprintf printf
|
||||
# define dbgprintf printf
|
||||
# define dbgputstr(characters, length) fwrite(characters, 1, length, stdout)
|
||||
# define dbgprintf(...) fprintf(stderr, __VA_ARGS__)
|
||||
# define dbgputstr(characters, length) fwrite(characters, 1, length, stderr)
|
||||
#endif
|
||||
|
@ -182,7 +182,7 @@ ByteBuffer IODevice::read_line(size_t max_size)
|
||||
return {};
|
||||
if (m_eof) {
|
||||
if (m_buffered_data.size() > max_size) {
|
||||
dbgprintf("IODevice::read_line: At EOF but there's more than max_size(%d) buffered\n", max_size);
|
||||
dbgprintf("IODevice::read_line: At EOF but there's more than max_size(%zu) buffered\n", max_size);
|
||||
return {};
|
||||
}
|
||||
auto buffer = ByteBuffer::copy(m_buffered_data.data(), m_buffered_data.size());
|
||||
|
Loading…
Reference in New Issue
Block a user