MCPcopy Create free account
hub / github.com/RangeNetworks/openbts / getUInt16

Method getUInt16

GPRS/ByteVector.cpp:339–346  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

337}
338
339unsigned ByteVector::getUInt16(size_t readIndex) const { // 2 byte value
340 BVASSERT(readIndex <= size() - 2);
341 uint16_t tmp;
342 ByteType *tp = (ByteType*)&tmp;
343 ByteType *cp = &mStart[readIndex];
344 tp[0]=cp[0]; tp[1]=cp[1];
345 return ntohs(tmp);
346}
347unsigned ByteVector::readUInt16(size_t &rp) {
348 unsigned result = getUInt16(rp);
349 rp+=2;

Callers 4

qosReadMethod · 0.80
gprsTestUlFunction · 0.80
parseDLUnitDataBodyMethod · 0.80
parseElementMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected