X-Git-Url: https://sigrok.org/gitweb/?a=blobdiff_plain;f=src%2Fhardware%2Fasix-sigma%2Fapi.c;h=4fdafec955eb1cfb1b1ef4eb112a2192f63b1e22;hb=08f023fe97e402d68106299d04726f9094f00c45;hp=dcccb4240669dd37b60b0dfea58dc5bbfc838839;hpb=5cc292b34aa5a4c2818b0db668f2b61702b994b9;p=libsigrok.git diff --git a/src/hardware/asix-sigma/api.c b/src/hardware/asix-sigma/api.c index dcccb424..4fdafec9 100644 --- a/src/hardware/asix-sigma/api.c +++ b/src/hardware/asix-sigma/api.c @@ -120,7 +120,7 @@ static GSList *scan(struct sr_dev_driver *di, GSList *options) char conn_id[20]; char serno_txt[16]; char *end; - long serno_num, serno_pre; + unsigned long serno_num, serno_pre; enum asix_device_type dev_type; const char *dev_text; struct sr_dev_inst *sdi; @@ -192,7 +192,7 @@ static GSList *scan(struct sr_dev_driver *di, GSList *options) * All ASIX logic analyzers have a serial number, which * reads as a hex number, and tells the device type. */ - ret = sr_atol_base(serno_txt, &serno_num, &end, 16); + ret = sr_atoul_base(serno_txt, &serno_num, &end, 16); if (ret != SR_OK || !end || *end) { sr_warn("Cannot interpret serial number %s.", serno_txt); continue;