Home
last modified time | relevance | path

Searched refs:mSock (Results 1 – 1 of 1) sorted by relevance

/hardware/qcom/sm8150/gps/utils/
DLocIpc.cpp135 shared_ptr<Sock> mSock; member in loc_util::LocIpcLocalSender
137 inline virtual bool isOperable() const override { return mSock != nullptr && mSock->isValid(); } in isOperable()
139 return mSock->send(data, length, 0, (struct sockaddr*)&mAddr, sizeof(mAddr)); in send()
143 mSock(make_shared<Sock>((nullptr == name) ? -1 : (::socket(AF_UNIX, SOCK_DGRAM, 0)))), in LocIpcLocalSender()
145 if (mSock != nullptr && mSock->isValid()) {
155 return mSock->recv(mDataCb, 0, (struct sockaddr*)&mAddr, &size); in recv()
166 if (mSock->isValid() && ::bind(mSock->mSid, (struct sockaddr*)&mAddr, sizeof(mAddr)) < 0) { in LocIpcLocalRecver()
167 LOC_LOGe("bind socket error. sock fd: %d, reason: %s", mSock->mSid, strerror(errno)); in LocIpcLocalRecver()
168 mSock->close(); in LocIpcLocalRecver()
175 mSock->sendAbort(0, (struct sockaddr*)&mAddr, sizeof(mAddr)); in abort()
[all …]