Minor fixes

- Fix a typo in OpenAL
- Fix typo in cellHttp.h
- Unused variables in catch
- Use 64-bit shifts
- Use use_count with shared pointers, unique is depracated and getting removed
- Explicitly cast boolean to int
- Signed/unsigned issues with loop variables
- Fix missing return statement (the code path is unreachable, but compiler wants a return)
- */ ouside of comment
- Fix duplicate layout name
This commit is contained in:
msuih 2019-06-28 10:16:14 +03:00 committed by Nekotekina
parent 1e0289bcb2
commit 690cdff0d3
10 changed files with 14 additions and 13 deletions

View file

@ -128,7 +128,7 @@ bool OpenALBackend::AddData(const void* src, u32 num_samples)
// Fail if there are no free buffers remaining // Fail if there are no free buffers remaining
if (m_num_unqueued == 0) if (m_num_unqueued == 0)
{ {
LOG_WARNING(GENERAL, "XAudio2Backend : no unqueued buffers remaining"); LOG_WARNING(GENERAL, "OpenALBackend : no unqueued buffers remaining");
return false; return false;
} }

View file

@ -125,7 +125,7 @@ enum
CELL_HTTPS_ERROR_CERT_KEY_MISMATCH = 0x80710a0a, CELL_HTTPS_ERROR_CERT_KEY_MISMATCH = 0x80710a0a,
CELL_HTTPS_ERROR_KEY_NEEDS_CERT = 0x80710a0b, CELL_HTTPS_ERROR_KEY_NEEDS_CERT = 0x80710a0b,
CELL_HTTPS_ERROR_CERT_NEEDS_KEY = 0x80710a0c, CELL_HTTPS_ERROR_CERT_NEEDS_KEY = 0x80710a0c,
CELL_HTTPS_ERROR_RETRY_CONNECTION = 0x80710a01d, CELL_HTTPS_ERROR_RETRY_CONNECTION = 0x80710a0d,
CELL_HTTPS_ERROR_NET_SSL_CONNECT = 0x80710b00, CELL_HTTPS_ERROR_NET_SSL_CONNECT = 0x80710b00,
CELL_HTTPS_ERROR_NET_SSL_SEND = 0x80710c00, CELL_HTTPS_ERROR_NET_SSL_SEND = 0x80710c00,
CELL_HTTPS_ERROR_NET_SSL_RECV = 0x80710d00, CELL_HTTPS_ERROR_NET_SSL_RECV = 0x80710d00,

View file

@ -4543,7 +4543,7 @@ public:
{ {
(this->*g_decoder.decode(op))({op}); (this->*g_decoder.decode(op))({op});
} }
catch (const std::exception& e) catch (const std::exception&)
{ {
std::string dump; std::string dump;
raw_string_ostream out(dump); raw_string_ostream out(dump);
@ -4762,7 +4762,7 @@ public:
// Create interpreter table // Create interpreter table
const auto if_type = get_ftype<void, u8*, u8*, u32, u32, u8*, u32, u8*>(); const auto if_type = get_ftype<void, u8*, u8*, u32, u32, u8*, u32, u8*>();
const auto if_pptr = if_type->getPointerTo()->getPointerTo(); const auto if_pptr = if_type->getPointerTo()->getPointerTo();
m_function_table = new GlobalVariable(*m_module, ArrayType::get(if_type->getPointerTo(), 1u << m_interp_magn), true, GlobalValue::InternalLinkage, nullptr); m_function_table = new GlobalVariable(*m_module, ArrayType::get(if_type->getPointerTo(), 1ull << m_interp_magn), true, GlobalValue::InternalLinkage, nullptr);
// Add return function // Add return function
const auto ret_func = cast<Function>(module->getOrInsertFunction("spu_ret", if_type).getCallee()); const auto ret_func = cast<Function>(module->getOrInsertFunction("spu_ret", if_type).getCallee());
@ -4823,7 +4823,7 @@ public:
// Fill interpreter table // Fill interpreter table
std::vector<llvm::Constant*> iptrs; std::vector<llvm::Constant*> iptrs;
iptrs.reserve(1u << m_interp_magn); iptrs.reserve(1ull << m_interp_magn);
m_block = nullptr; m_block = nullptr;
@ -4987,7 +4987,7 @@ public:
} }
} }
} }
catch (const std::exception& e) catch (const std::exception&)
{ {
std::string dump; std::string dump;
raw_string_ostream out(dump); raw_string_ostream out(dump);
@ -5011,7 +5011,7 @@ public:
} }
} }
m_function_table->setInitializer(ConstantArray::get(ArrayType::get(if_type->getPointerTo(), 1u << m_interp_magn), iptrs)); m_function_table->setInitializer(ConstantArray::get(ArrayType::get(if_type->getPointerTo(), 1ull << m_interp_magn), iptrs));
m_function_table = nullptr; m_function_table = nullptr;
// Initialize pass manager // Initialize pass manager

View file

@ -218,7 +218,7 @@ error_code sys_mmapper_free_address(u32 addr)
return {CELL_EINVAL, addr}; return {CELL_EINVAL, addr};
} }
if (!area.unique()) if (area.use_count() != 1)
{ {
return CELL_EBUSY; return CELL_EBUSY;
} }

View file

@ -988,7 +988,7 @@ namespace vm
continue; continue;
} }
if (must_be_empty && (!it->unique() || (*it)->imp_used(lock))) if (must_be_empty && (it->use_count() != 1 || (*it)->imp_used(lock)))
{ {
return *it; return *it;
} }

View file

@ -481,7 +481,7 @@ VKGSRender::VKGSRender() : GSRender()
m_occlusion_query_pool.create((*m_device), OCCLUSION_MAX_POOL_SIZE); m_occlusion_query_pool.create((*m_device), OCCLUSION_MAX_POOL_SIZE);
m_occlusion_map.resize(occlusion_query_count); m_occlusion_map.resize(occlusion_query_count);
for (int n = 0; n < occlusion_query_count; ++n) for (u32 n = 0; n < occlusion_query_count; ++n)
m_occlusion_query_data[n].driver_handle = n; m_occlusion_query_data[n].driver_handle = n;
//Generate frame contexts //Generate frame contexts

View file

@ -780,6 +780,7 @@ namespace
case rsx::vertex_base_type::cmp: return "CMP"; case rsx::vertex_base_type::cmp: return "CMP";
case rsx::vertex_base_type::ub256: return "Unsigned byte unormalized"; case rsx::vertex_base_type::ub256: return "Unsigned byte unormalized";
} }
return "";
} }
std::string unpack_vertex_format(u32 arg) std::string unpack_vertex_format(u32 arg)

View file

@ -685,7 +685,7 @@ void pad_settings_dialog::mouseReleaseEvent(QMouseEvent* event)
ReactivateButtons(); ReactivateButtons();
} }
void pad_settings_dialog::mouseMoveEvent(QMouseEvent*/* event*/) void pad_settings_dialog::mouseMoveEvent(QMouseEvent* /*event*/)
{ {
if (m_handler->m_type != pad_handler::keyboard) if (m_handler->m_type != pad_handler::keyboard)
{ {

View file

@ -207,7 +207,7 @@ namespace gui
table->clearContents(); table->clearContents();
table->setRowCount(0); table->setRowCount(0);
for (u32 i = 0; i < item_count; ++i) for (int i = 0; i < item_count; ++i)
table->insertRow(i); table->insertRow(i);
if (table->horizontalScrollBar()) if (table->horizontalScrollBar())

View file

@ -1239,7 +1239,7 @@
<property name="title"> <property name="title">
<string>Disk cache</string> <string>Disk cache</string>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout_75"> <layout class="QVBoxLayout" name="verticalLayout_77">
<item> <item>
<widget class="QCheckBox" name="enableCacheClearing"> <widget class="QCheckBox" name="enableCacheClearing">
<property name="text"> <property name="text">