MCPcopy Create free account
hub / github.com/Tripwire/tripwire-open-source / GetShort

Method GetShort

src/cryptlib/cryptlib.cpp:108–122  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

106}
107
108int BufferedTransformation::GetShort(word16 &value, bool highFirst)
109{
110 if (MaxRetrieveable()<2)
111 return 0;
112
113 byte buf[2];
114 Get(buf, 2);
115
116 if (highFirst)
117 value = (buf[0] << 8) | buf[1];
118 else
119 value = (buf[1] << 8) | buf[0];
120
121 return 2;
122}
123
124int BufferedTransformation::GetLong(word32 &value, bool highFirst)
125{

Callers 1

~BERSequenceDecoderMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected