Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(137)

Unified Diff: ppapi/native_client/src/shared/ppapi_proxy/object_serialize.cc

Issue 9253011: Pepper SRPC proxy style and type nits (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix bad license to pass presubmit check Created 8 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: ppapi/native_client/src/shared/ppapi_proxy/object_serialize.cc
diff --git a/ppapi/native_client/src/shared/ppapi_proxy/object_serialize.cc b/ppapi/native_client/src/shared/ppapi_proxy/object_serialize.cc
index 1d73cfb39788d699e570fe683e86c2bd59a88c91..7d295027606fcb1c087890c6133dc630689593ea 100644
--- a/ppapi/native_client/src/shared/ppapi_proxy/object_serialize.cc
+++ b/ppapi/native_client/src/shared/ppapi_proxy/object_serialize.cc
@@ -197,8 +197,7 @@ bool SerializePpVar(const PP_Var* vars,
element_size = sizeof(SerializedFixed);
break;
case PP_VARTYPE_BOOL:
- s->u.boolean_value = static_cast<bool>
- (PP_TRUE == vars[i].value.as_bool);
+ s->u.boolean_value = PP_ToBool(vars[i].value.as_bool);
element_size = sizeof(SerializedFixed);
break;
case PP_VARTYPE_INT32:
@@ -410,7 +409,7 @@ bool DeserializePpVar(char* bytes,
case PP_VARTYPE_NULL:
break;
case PP_VARTYPE_BOOL:
- vars[i].value.as_bool = static_cast<PP_Bool>(s->u.boolean_value);
+ vars[i].value.as_bool = PP_FromBool(s->u.boolean_value);
break;
case PP_VARTYPE_INT32:
vars[i].value.as_int = s->u.int32_value;

Powered by Google App Engine
This is Rietveld 408576698