Coverage Report

Created: 2025-06-16 07:00

/src/libraw/internal/libraw_checked_buffer.h
Line
Count
Source (jump to first uncovered line)
1
#pragma once
2
3
#include <vector>
4
#include "../libraw/libraw_types.h"
5
6
class checked_buffer_t
7
{
8
public:
9
  // create with internal storage
10
  checked_buffer_t(short ord, int size);
11
  checked_buffer_t(short ord, unsigned char *dd, int ss);
12
  ushort sget2(int offset);
13
0
  ushort sget2LL(INT64 offset) { return sget2(int(offset)); }
14
  void checkoffset(int off);
15
  unsigned char operator[](int idx);
16
  unsigned sget4(int offset);
17
0
  unsigned sget4LL(INT64 offset) { return sget4(int(offset)); }
18
  double sgetreal(int type, int offset);
19
0
  float sgetrealf(int type, int offset) { return float(sgetreal(type, offset)); }
20
12.9M
    unsigned char *data() { return _data; }
21
 
22
  int tiff_sget(unsigned save, INT64 *tag_offset, unsigned *tag_id, unsigned *tag_type, INT64 *tag_dataoffset,
23
    unsigned *tag_datalen, int *tag_dataunitlen);
24
protected:
25
  short _order;
26
27
 private:
28
  unsigned char *_data;
29
  int _len;
30
  std::vector<unsigned char> storage;
31
};