static const uint64_t timebases[][2] = {
/* picoseconds */
- { 20, 1000000000000 },
- { 50, 1000000000000 },
- { 100, 1000000000000 },
- { 200, 1000000000000 },
- { 500, 1000000000000 },
+ { 20, UINT64_C(1000000000000) },
+ { 50, UINT64_C(1000000000000) },
+ { 100, UINT64_C(1000000000000) },
+ { 200, UINT64_C(1000000000000) },
+ { 500, UINT64_C(1000000000000) },
/* nanoseconds */
{ 1, 1000000000 },
{ 2, 1000000000 },
return SR_ERR;
if (analog.num_samples == 0) {
+ g_free(analog.data);
+
/* No data available, we have to acquire data first. */
g_snprintf(command, sizeof(command), "ARM;WAIT;*OPC;C%d:WAVEFORM?", ch->index + 1);
sr_scpi_send(sdi->conn, command);