Skip to content

Commit

Permalink
Bug 1156352: Remove |UnixSocketRawData| from RIL interfaces, r=htsai
Browse files Browse the repository at this point in the history
  • Loading branch information
tdz committed Apr 23, 2015
1 parent 7f554d1 commit be8cf39
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions ipc/ril/Ril.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -163,16 +163,16 @@ ConnectWorkerToRIL::RunTask(JSContext* aCx)
class DispatchRILEvent final : public WorkerTask
{
public:
DispatchRILEvent(unsigned long aClient, UnixSocketRawData* aMessage)
DispatchRILEvent(unsigned long aClient, UnixSocketBuffer* aBuffer)
: mClientId(aClient)
, mMessage(aMessage)
, mBuffer(aBuffer)
{ }

bool RunTask(JSContext* aCx) override;

private:
unsigned long mClientId;
nsAutoPtr<UnixSocketRawData> mMessage;
nsAutoPtr<UnixSocketBuffer> mBuffer;
};

bool
Expand All @@ -181,14 +181,14 @@ DispatchRILEvent::RunTask(JSContext* aCx)
JS::Rooted<JSObject*> obj(aCx, JS::CurrentGlobalOrNull(aCx));

JS::Rooted<JSObject*> array(aCx,
JS_NewUint8Array(aCx, mMessage->GetSize()));
JS_NewUint8Array(aCx, mBuffer->GetSize()));
if (!array) {
return false;
}
{
JS::AutoCheckCannotGC nogc;
memcpy(JS_GetArrayBufferViewData(array, nogc),
mMessage->GetData(), mMessage->GetSize());
mBuffer->GetData(), mBuffer->GetSize());
}

JS::AutoValueArray<2> args(aCx);
Expand Down

0 comments on commit be8cf39

Please sign in to comment.