aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGravatar Subv <subv2112@gmail.com>2015-02-07 13:05:17 -0500
committerGravatar Yuri Kunde Schlesner <yuriks@yuriks.net>2015-02-10 13:43:44 -0200
commitca1a87ef7d32a938c1ed3a59f8638cca54071a24 (patch)
treed1cc8339728f3ca029f4dbd66de86306669f73ac
parent3f1a3952d707bce7851652ce54701ca14334f314 (diff)
ResultVal: Fixed compilation when reassigning a ResultVal.
-rw-r--r--src/core/hle/result.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/core/hle/result.h b/src/core/hle/result.h
index 948b9e38..9c6ca29e 100644
--- a/src/core/hle/result.h
+++ b/src/core/hle/result.h
@@ -307,14 +307,14 @@ public:
}
ResultVal& operator=(const ResultVal& o) {
- if (*this) {
- if (o) {
+ if (!empty()) {
+ if (!o.empty()) {
*GetPointer() = *o.GetPointer();
} else {
GetPointer()->~T();
}
} else {
- if (o) {
+ if (!o.empty()) {
new (&storage) T(*o.GetPointer());
}
}