summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorGravatar bunnei2014-06-06 00:23:33 -0400
committerGravatar bunnei2014-06-13 09:51:12 -0400
commit5365ca157d5cb81c5cba3922036839f3c58e85ba (patch)
tree378f5d44b7bdc70795ff10dc40be90ae2465eb36 /src
parentHLE: Updated various handle debug assertions to be more clear. (diff)
downloadyuzu-5365ca157d5cb81c5cba3922036839f3c58e85ba.tar.gz
yuzu-5365ca157d5cb81c5cba3922036839f3c58e85ba.tar.xz
yuzu-5365ca157d5cb81c5cba3922036839f3c58e85ba.zip
Kernel: Updated various kernel function "name" arguments to be const references.
Diffstat (limited to 'src')
-rw-r--r--src/core/hle/kernel/event.cpp4
-rw-r--r--src/core/hle/kernel/event.h2
-rw-r--r--src/core/hle/kernel/mutex.cpp4
-rw-r--r--src/core/hle/kernel/mutex.h2
4 files changed, 6 insertions, 6 deletions
diff --git a/src/core/hle/kernel/event.cpp b/src/core/hle/kernel/event.cpp
index 72a190f8c..3a522c190 100644
--- a/src/core/hle/kernel/event.cpp
+++ b/src/core/hle/kernel/event.cpp
@@ -139,7 +139,7 @@ Result ClearEvent(Handle handle) {
139 * @param name Optional name of event 139 * @param name Optional name of event
140 * @return Newly created Event object 140 * @return Newly created Event object
141 */ 141 */
142Event* CreateEvent(Handle& handle, const ResetType reset_type, const std::string name) { 142Event* CreateEvent(Handle& handle, const ResetType reset_type, const std::string& name) {
143 Event* evt = new Event; 143 Event* evt = new Event;
144 144
145 handle = Kernel::g_object_pool.Create(evt); 145 handle = Kernel::g_object_pool.Create(evt);
@@ -158,7 +158,7 @@ Event* CreateEvent(Handle& handle, const ResetType reset_type, const std::string
158 * @param name Optional name of event 158 * @param name Optional name of event
159 * @return Handle to newly created Event object 159 * @return Handle to newly created Event object
160 */ 160 */
161Handle CreateEvent(const ResetType reset_type, const std::string name) { 161Handle CreateEvent(const ResetType reset_type, const std::string& name) {
162 Handle handle; 162 Handle handle;
163 Event* evt = CreateEvent(handle, reset_type, name); 163 Event* evt = CreateEvent(handle, reset_type, name);
164 return handle; 164 return handle;
diff --git a/src/core/hle/kernel/event.h b/src/core/hle/kernel/event.h
index 3527b01fd..c39b33180 100644
--- a/src/core/hle/kernel/event.h
+++ b/src/core/hle/kernel/event.h
@@ -47,6 +47,6 @@ Result ClearEvent(Handle handle);
47 * @param name Optional name of event 47 * @param name Optional name of event
48 * @return Handle to newly created Event object 48 * @return Handle to newly created Event object
49 */ 49 */
50Handle CreateEvent(const ResetType reset_type, const std::string name="Unknown"); 50Handle CreateEvent(const ResetType reset_type, const std::string& name="Unknown");
51 51
52} // namespace 52} // namespace
diff --git a/src/core/hle/kernel/mutex.cpp b/src/core/hle/kernel/mutex.cpp
index ee7507edf..a76c8de03 100644
--- a/src/core/hle/kernel/mutex.cpp
+++ b/src/core/hle/kernel/mutex.cpp
@@ -137,7 +137,7 @@ Result ReleaseMutex(Handle handle) {
137 * @param name Optional name of mutex 137 * @param name Optional name of mutex
138 * @return Pointer to new Mutex object 138 * @return Pointer to new Mutex object
139 */ 139 */
140Mutex* CreateMutex(Handle& handle, bool initial_locked, const std::string name) { 140Mutex* CreateMutex(Handle& handle, bool initial_locked, const std::string& name) {
141 Mutex* mutex = new Mutex; 141 Mutex* mutex = new Mutex;
142 handle = Kernel::g_object_pool.Create(mutex); 142 handle = Kernel::g_object_pool.Create(mutex);
143 143
@@ -161,7 +161,7 @@ Mutex* CreateMutex(Handle& handle, bool initial_locked, const std::string name)
161 * @param name Optional name of mutex 161 * @param name Optional name of mutex
162 * @return Handle to newly created object 162 * @return Handle to newly created object
163 */ 163 */
164Handle CreateMutex(bool initial_locked, std::string name) { 164Handle CreateMutex(bool initial_locked, const std::string& name) {
165 Handle handle; 165 Handle handle;
166 Mutex* mutex = CreateMutex(handle, initial_locked, name); 166 Mutex* mutex = CreateMutex(handle, initial_locked, name);
167 return handle; 167 return handle;
diff --git a/src/core/hle/kernel/mutex.h b/src/core/hle/kernel/mutex.h
index fde5549fa..7d7b5137e 100644
--- a/src/core/hle/kernel/mutex.h
+++ b/src/core/hle/kernel/mutex.h
@@ -23,6 +23,6 @@ Result ReleaseMutex(Handle handle);
23 * @param name Optional name of mutex 23 * @param name Optional name of mutex
24 * @return Handle to newly created object 24 * @return Handle to newly created object
25 */ 25 */
26Handle CreateMutex(bool initial_locked, const std::string name="Unknown"); 26Handle CreateMutex(bool initial_locked, const std::string& name="Unknown");
27 27
28} // namespace 28} // namespace