Merge branch 'master' into d3d12

This commit is contained in:
Triang3l 2018-11-24 18:40:22 +03:00
commit cb4fb451bf
2 changed files with 6 additions and 4 deletions

View File

@ -156,9 +156,12 @@ class Logger {
void WriteThread() { void WriteThread() {
RingBuffer rb(buffer_, kBufferSize); RingBuffer rb(buffer_, kBufferSize);
uint32_t idle_loops = 0; uint32_t idle_loops = 0;
while (running_) { while (true) {
bool did_write = false; bool did_write = false;
rb.set_write_offset(write_tail_); rb.set_write_offset(write_tail_);
if (!running_ && rb.empty()) {
break;
}
while (!rb.empty()) { while (!rb.empty()) {
did_write = true; did_write = true;

View File

@ -502,9 +502,8 @@ void UserModule::Dump() {
} }
auto library_data = auto library_data =
reinterpret_cast<const uint8_t*>(opt_import_libraries) + reinterpret_cast<const uint8_t*>(opt_import_libraries);
opt_import_libraries->string_table.size + 12; uint32_t library_offset = opt_import_libraries->string_table.size + 12;
uint32_t library_offset = 0;
while (library_offset < opt_import_libraries->size) { while (library_offset < opt_import_libraries->size) {
auto library = reinterpret_cast<const xex2_import_library*>( auto library = reinterpret_cast<const xex2_import_library*>(
library_data + library_offset); library_data + library_offset);