]> sigrok.org Git - libsigrok.git/commit
rigol-dg: free memory that was allocated by SCPI get routines
authorGerhard Sittig <redacted>
Sun, 16 May 2021 12:45:47 +0000 (14:45 +0200)
committerGerhard Sittig <redacted>
Sat, 22 May 2021 06:06:58 +0000 (08:06 +0200)
commitff85a7f0ab3cedf0b44b48e6f3e59da9c767d53b
tree51bdcccd8d47c48567e50516d96e3cf4c6af232b
parent36165cf0f7a226f76d3e9832a70e06d9d0d634ec
rigol-dg: free memory that was allocated by SCPI get routines

The SCPI get routines may allocate memory for response data which
callers have to free after use.

Move an existing release call to an earlier location, to avoid leaking
memory when an error path is taken.

This addresses part of bug #1683.
src/hardware/rigol-dg/api.c