Add error message if scale and data vector lengths do not match

This commit is contained in:
Holger Vogt 2026-06-09 17:57:39 +02:00
parent 3d02373664
commit 21907e5bf7
1 changed files with 7 additions and 1 deletions

View File

@ -842,7 +842,13 @@ measure_minMaxAvg(
}
if (dScale->v_realdata == NULL && dScale->v_compdata == NULL) {
fprintf(cp_err, "Error: scale vector time, frequency or ?-sweep has no data.\n");
fprintf(cp_err, "Error: scale vector %s has no data.\n", dScale->v_name);
return MEASUREMENT_FAILURE;
}
if (d->v_length != dScale->v_length) {
fprintf(cp_err, "Error: length of scale vector (%s) does not match length of data vector (%s).\n", dScale->v_name, d->v_name);
fprintf(cp_err, " Analysis is not possible.\n");
return MEASUREMENT_FAILURE;
}