summaryrefslogtreecommitdiffstats
path: root/ddcprobe
diff options
context:
space:
mode:
authornalin <nalin>1999-07-19 02:07:57 +0000
committernalin <nalin>1999-07-19 02:07:57 +0000
commit61d01a7ad426852a9d051e581611bdd2b820d2f9 (patch)
treef3fbc7ab1145ecd32d52e0d613355a8d3f64f3e5 /ddcprobe
parent3f718154f60cb6ad73fa0f81b0181dd4e0fb72b8 (diff)
downloadanaconda-61d01a7ad426852a9d051e581611bdd2b820d2f9.tar.gz
anaconda-61d01a7ad426852a9d051e581611bdd2b820d2f9.tar.xz
anaconda-61d01a7ad426852a9d051e581611bdd2b820d2f9.zip
fix no newline-before-modeline problem
Diffstat (limited to 'ddcprobe')
-rw-r--r--ddcprobe/ddcxinfo.c16
1 files changed, 12 insertions, 4 deletions
diff --git a/ddcprobe/ddcxinfo.c b/ddcprobe/ddcxinfo.c
index 2172f32f1..7db82a877 100644
--- a/ddcprobe/ddcxinfo.c
+++ b/ddcprobe/ddcxinfo.c
@@ -19,13 +19,19 @@ int main(int argc, char **argv)
for(i = 1; i < argc; i++) {
if(strcmp(argv[i], "-hsync") == 0) {
vbe_get_edid_ranges(&hmin, &hmax, &vmin, &vmax);
- if(hmin || hmax)
+ if(hmin || hmax) {
printf("%d-%d\n", hmin, hmax);
+ } else {
+ return 1;
+ }
}
if(strcmp(argv[i], "-vsync") == 0) {
vbe_get_edid_ranges(&hmin, &hmax, &vmin, &vmax);
- if(vmin || vmax)
+ if(vmin || vmax) {
printf("%d-%d\n", vmin, vmax);
+ } else {
+ return 1;
+ }
}
if(strcmp(argv[i], "-modelines") == 0) {
struct vbe_modeline* modelines;
@@ -36,13 +42,15 @@ int main(int argc, char **argv)
modelines[j].width,
modelines[j].height,
modelines[j].refresh,
- modelines[j].modeline,
- modelines[j].interlaced?"i":"");
+ modelines[j].interlaced?"i":"",
+ modelines[j].modeline);
free(modelines[j].modeline);
}
}
if(modelines) {
free(modelines);
+ } else {
+ return 1;
}
}
}