- hwopt->value = g_strdup(value);
- opts = g_slist_append(opts, hwopt);
+ src->value = g_strdup(value);
+ opts = g_slist_append(opts, src);
/* Unknown options, already logged. */
return NULL;
devices = sr_driver_scan(driver, drvopts);
/* Unknown options, already logged. */
return NULL;
devices = sr_driver_scan(driver, drvopts);
NULL) == SR_OK) && hwopts) {
printf("Supported driver options:\n");
for (i = 0; hwopts[i]; i++) {
NULL) == SR_OK) && hwopts) {
printf("Supported driver options:\n");
for (i = 0; hwopts[i]; i++) {
if (sr_info_get(sdi->driver, SR_DI_PATTERNS,
(const void **)&stropts, sdi) == SR_OK) {
printf(" - supported patterns:\n");
if (sr_info_get(sdi->driver, SR_DI_PATTERNS,
(const void **)&stropts, sdi) == SR_OK) {
printf(" - supported patterns:\n");
if (sr_info_get(sdi->driver, SR_DI_SAMPLERATES,
(const void **)&samplerates, sdi) != SR_OK) {
printf("\n");
if (sr_info_get(sdi->driver, SR_DI_SAMPLERATES,
(const void **)&samplerates, sdi) != SR_OK) {
printf("\n");
if (sr_info_get(sdi->driver, SR_DI_BUFFERSIZES,
(const void **)&integers, sdi) != SR_OK) {
printf("\n");
if (sr_info_get(sdi->driver, SR_DI_BUFFERSIZES,
(const void **)&integers, sdi) != SR_OK) {
printf("\n");
for (i = 0; integers[i]; i++)
printf(" %"PRIu64"\n", integers[i]);
for (i = 0; integers[i]; i++)
printf(" %"PRIu64"\n", integers[i]);
if (sr_info_get(sdi->driver, SR_DI_TIMEBASES,
(const void **)&rationals, sdi) != SR_OK) {
printf("\n");
if (sr_info_get(sdi->driver, SR_DI_TIMEBASES,
(const void **)&rationals, sdi) != SR_OK) {
printf("\n");
printf(" %s\n", sr_period_string(
rationals[i].p * rationals[i].q));
printf(" %s\n", sr_period_string(
rationals[i].p * rationals[i].q));
if (sr_info_get(sdi->driver, SR_DI_TRIGGER_SOURCES,
(const void **)&stropts, sdi) != SR_OK) {
printf("\n");
if (sr_info_get(sdi->driver, SR_DI_TRIGGER_SOURCES,
(const void **)&stropts, sdi) != SR_OK) {
printf("\n");
for (i = 0; stropts[i]; i++)
printf(" %s\n", stropts[i]);
for (i = 0; stropts[i]; i++)
printf(" %s\n", stropts[i]);
if (sr_info_get(sdi->driver, SR_DI_FILTERS,
(const void **)&stropts, sdi) != SR_OK) {
printf("\n");
if (sr_info_get(sdi->driver, SR_DI_FILTERS,
(const void **)&stropts, sdi) != SR_OK) {
printf("\n");
for (i = 0; stropts[i]; i++)
printf(" %s\n", stropts[i]);
for (i = 0; stropts[i]; i++)
printf(" %s\n", stropts[i]);
if (sr_info_get(sdi->driver, SR_DI_VDIVS,
(const void **)&rationals, sdi) != SR_OK) {
printf("\n");
if (sr_info_get(sdi->driver, SR_DI_VDIVS,
(const void **)&rationals, sdi) != SR_OK) {
printf("\n");
for (i = 0; rationals[i].p && rationals[i].q; i++)
printf(" %s\n", sr_voltage_string( &rationals[i]));
for (i = 0; rationals[i].p && rationals[i].q; i++)
printf(" %s\n", sr_voltage_string( &rationals[i]));
if (sr_info_get(sdi->driver, SR_DI_COUPLING,
(const void **)&stropts, sdi) != SR_OK) {
printf("\n");
if (sr_info_get(sdi->driver, SR_DI_COUPLING,
(const void **)&stropts, sdi) != SR_OK) {
printf("\n");
g_hash_table_iter_init(&iter, args);
while (g_hash_table_iter_next(&iter, &key, &value)) {
g_hash_table_iter_init(&iter, args);
while (g_hash_table_iter_next(&iter, &key, &value)) {