mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
core: convert ostctools as C++
Replace some of the memory management by C++ idioms. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
parent
fe0bb905f3
commit
b74703b61d
4 changed files with 54 additions and 66 deletions
|
@ -31,24 +31,24 @@ struct divelog;
|
|||
struct devices;
|
||||
|
||||
typedef struct {
|
||||
dc_descriptor_t *descriptor;
|
||||
const char *vendor, *product, *devname;
|
||||
const char *model, *btname;
|
||||
unsigned char *fingerprint;
|
||||
unsigned int fsize, fdeviceid, fdiveid;
|
||||
struct dc_event_devinfo_t devinfo;
|
||||
uint32_t diveid;
|
||||
dc_device_t *device;
|
||||
dc_context_t *context;
|
||||
dc_iostream_t *iostream;
|
||||
bool force_download;
|
||||
bool libdc_log;
|
||||
bool libdc_dump;
|
||||
bool bluetooth_mode;
|
||||
bool sync_time;
|
||||
FILE *libdc_logfile;
|
||||
struct divelog *log;
|
||||
void *androidUsbDeviceDescriptor;
|
||||
dc_descriptor_t *descriptor = nullptr;
|
||||
const char *vendor = nullptr, *product = nullptr, *devname = nullptr;
|
||||
const char *model = nullptr, *btname = nullptr;
|
||||
unsigned char *fingerprint = nullptr;
|
||||
unsigned int fsize = 0, fdeviceid = 0, fdiveid = 0;
|
||||
struct dc_event_devinfo_t devinfo = { };
|
||||
uint32_t diveid = 0;
|
||||
dc_device_t *device = nullptr;
|
||||
dc_context_t *context = nullptr;
|
||||
dc_iostream_t *iostream = nullptr;
|
||||
bool force_download = false;
|
||||
bool libdc_log = false;
|
||||
bool libdc_dump = false;
|
||||
bool bluetooth_mode = false;
|
||||
bool sync_time = false;
|
||||
FILE *libdc_logfile = nullptr;
|
||||
struct divelog *log = nullptr;
|
||||
void *androidUsbDeviceDescriptor = nullptr;
|
||||
} device_data_t;
|
||||
|
||||
const char *errmsg (dc_status_t rc);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue