]> sigrok.org Git - libsigrok.git/blobdiff - src/hardware/rigol-ds/api.c
rigol-ds: fix search for the closest vdiv.
[libsigrok.git] / src / hardware / rigol-ds / api.c
index 257bd11ee082df2d7eccfcc473562178380e4783..c25f9ef51ca0d39d5def1ff89939c2892ab5f45c 100644 (file)
@@ -502,7 +502,7 @@ static int config_get(uint32_t key, GVariant **data, const struct sr_dev_inst *s
        const char *tmp_str;
        uint64_t samplerate;
        int analog_channel = -1;
-       float smallest_diff = 0.0000000001;
+       float smallest_diff = INFINITY;
        int idx = -1;
        unsigned i;