aboutsummaryrefslogtreecommitdiffstats
path: root/searchsummary/src/vespa/searchsummary/docsummary/resultclass.h
diff options
context:
space:
mode:
authorArne H Juul <arnej@yahooinc.com>2022-02-04 16:28:41 +0000
committerArne H Juul <arnej@yahooinc.com>2022-02-04 16:28:41 +0000
commit917b19c8d7c6e27750a4e4404378071c6f4aa7c7 (patch)
tree7357ae36ef7201bda89285847d872d1037e2e445 /searchsummary/src/vespa/searchsummary/docsummary/resultclass.h
parent857c68c6e9da9f4915de5e975d06fe423e0959e7 (diff)
remove check for compressed data
* as I can't find any place that could possibly put zlib compressed data into these classes
Diffstat (limited to 'searchsummary/src/vespa/searchsummary/docsummary/resultclass.h')
-rw-r--r--searchsummary/src/vespa/searchsummary/docsummary/resultclass.h29
1 files changed, 4 insertions, 25 deletions
diff --git a/searchsummary/src/vespa/searchsummary/docsummary/resultclass.h b/searchsummary/src/vespa/searchsummary/docsummary/resultclass.h
index 858fdea2404..547c21d7a3f 100644
--- a/searchsummary/src/vespa/searchsummary/docsummary/resultclass.h
+++ b/searchsummary/src/vespa/searchsummary/docsummary/resultclass.h
@@ -71,10 +71,7 @@ struct ResEntry
void *_pt;
};
- bool _extract_field(search::RawBuf *target) const;
-
- uint32_t _get_length() const { return (_len & 0x7fffffff); }
- bool _is_compressed() const { return (_len & 0x80000000) != 0; }
+ uint32_t _get_length() const { return _len; }
uint32_t _get_real_length() const
{
// precond: IsVariableSize(_type) && _len >= sizeof(uint32_t)
@@ -83,29 +80,11 @@ struct ResEntry
memcpy(&rlen, _pt, sizeof(rlen));
return rlen;
}
- const void *_get_compressed() const
- {
- // precond: IsVariableSize(_type) && _len >= sizeof(uint32_t)
-
- return (const void *)(((const char *) _pt) + sizeof(uint32_t));
- }
- void _resolve_field(const char **buf, uint32_t *buflen,
- search::RawBuf *target) const
+ void _resolve_field(const char **buf, uint32_t *buflen, search::RawBuf *) const
{
// precond: IsVariableSize(_type)
-
- if (_is_compressed()) {
- if (_extract_field(target)) {
- *buf = target->GetDrainPos();
- *buflen = target->GetUsedLen();
- } else {
- *buf = NULL;
- *buflen = 0;
- }
- } else {
- *buf = (char *) _pt;
- *buflen = _len;
- }
+ *buf = (char *) _pt;
+ *buflen = _len;
}
};