summaryrefslogtreecommitdiffstats
path: root/ppapi
diff options
context:
space:
mode:
Diffstat (limited to 'ppapi')
-rw-r--r--ppapi/thunk/ppb_websocket_thunk.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/ppapi/thunk/ppb_websocket_thunk.cc b/ppapi/thunk/ppb_websocket_thunk.cc
index 1f49c3e..ca12d6b 100644
--- a/ppapi/thunk/ppb_websocket_thunk.cc
+++ b/ppapi/thunk/ppb_websocket_thunk.cc
@@ -71,14 +71,14 @@ int32_t SendMessage(PP_Resource resource, PP_Var message) {
uint64_t GetBufferedAmount(PP_Resource resource) {
EnterResource<PPB_WebSocket_API> enter(resource, false);
if (enter.failed())
- return PP_ERROR_BADRESOURCE;
+ return 0;
return enter.object()->GetBufferedAmount();
}
uint16_t GetCloseCode(PP_Resource resource) {
EnterResource<PPB_WebSocket_API> enter(resource, false);
if (enter.failed())
- return PP_ERROR_BADRESOURCE;
+ return 0;
return enter.object()->GetCloseCode();
}