]> sigrok.org Git - libsigrok.git/commitdiff
scpi: Use sr_atof_ascii() instead of sr_atof().
authorpoljar (Damir Jelić) <redacted>
Thu, 16 Jan 2014 14:28:49 +0000 (15:28 +0100)
committerBert Vermeulen <redacted>
Thu, 16 Jan 2014 15:27:35 +0000 (16:27 +0100)
hardware/common/scpi.c

index 8093490886d8eace63ece67a5ddbde6f4d880db8..591b9770f8b1a0a40326209e2dcd51380f8ab2e4 100644 (file)
@@ -404,7 +404,7 @@ SR_PRIV int sr_scpi_get_float(struct sr_scpi_dev_inst *scpi,
                if (!response)
                        return SR_ERR;
 
-       if (sr_atof(response, scpi_response) == SR_OK)
+       if (sr_atof_ascii(response, scpi_response) == SR_OK)
                ret = SR_OK;
        else
                ret = SR_ERR;
@@ -505,7 +505,7 @@ SR_PRIV int sr_scpi_get_floatv(struct sr_scpi_dev_inst *scpi,
        response_array = g_array_sized_new(TRUE, FALSE, sizeof(float), 256);
 
        while (*ptr) {
-               if (sr_atof(*ptr, &tmp) == SR_OK)
+               if (sr_atof_ascii(*ptr, &tmp) == SR_OK)
                        response_array = g_array_append_val(response_array,
                                                            tmp);
                else