summaryrefslogtreecommitdiff
path: root/xvinfo.c
AgeCommit message (Collapse)Author
2018-09-22Fix sign mismatch warnings for loop index comparisonsAlan Coopersmith
xvinfo.c: In function ‘main’: xvinfo.c:99:23: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] for (j = 0; j < nadaptors; j++) { ^ xvinfo.c:129:31: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] for (k = 0; k < ainfo[j].num_formats; k++, format++) { ^ xvinfo.c:198:31: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] for (n = 0; n < nencode; n++) { ^ xvinfo.c:207:35: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] for (n = 0; n < nencode; n++) { ^ xvinfo.c:222:35: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] for (n = 0; n < nencode; n++) { ^ Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2018-09-22Make xvinfo not exit with error in normal operationAlan Coopersmith
Fixes https://bugs.freedesktop.org/show_bug.cgi?id=74227 aka https://gitlab.freedesktop.org/xorg/app/xvinfo/issues/1 Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2018-03-24Properly handle failures of Xv query functions.Tobias Stoeckmann
If one of the query functions fail, xvinfo does not properly handle these cases and will most likely run into a segmentation fault due to accessing uninitialized variables (which includes pointers). Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org> Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2014-06-03Print which option was in error along with usage messageAlan Coopersmith
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2013-10-18Make ImageEncodings unsignedAlan Coopersmith
Starts at 0 and increments to count encodings - should never go negative. Fixes clang warnings: xvinfo.c:184:31: warning: implicit conversion changes signedness: 'int' to 'unsigned int' [-Wsign-conversion] if (nencode - ImageEncodings) { ~ ^~~~~~~~~~~~~~ xvinfo.c:186:39: warning: implicit conversion changes signedness: 'int' to 'unsigned int' [-Wsign-conversion] nencode - ImageEncodings); ~ ^~~~~~~~~~~~~~ Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2013-10-18Convert sprintf call to use snprintfAlan Coopersmith
Should be impossible to overflow with previous sprintf code, but still safer to avoid bugs if something changes in the future. Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2013-07-07Use progname for error messages as wellAlan Coopersmith
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2013-07-07Use real program name for help messageStéphane Aulery
Signed-off-by: Stéphane Aulery <lkppo@free.fr> Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com> Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2013-01-13Add -version optionAlan Coopersmith
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2013-01-13add explicit braces to clarify which if the else goes withAlan Coopersmith
Suggested by clang: xvinfo.c:125:25: warning: add explicit braces to avoid dangling else [-Wdangling-else] else ^ Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2013-01-13Convert from haphazard indenting to X.Org common styleAlan Coopersmith
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2013-01-13Add _X_NORETURN to PrintUsage to clear gcc/clang warningsAlan Coopersmith
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2010-10-06Purge cvs tags.Jesse Adkins
Signed-off-by: Jesse Adkins <jesserayadkins@gmail.com> Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2009-08-03added -short optionArthur HUILLET
2007-01-15Fix FourCC name output on big endian platforms.Michel Dänzer
Fixes https://bugs.freedesktop.org/show_bug.cgi?id=9665 .
2004-04-23Merging XORG-CURRENT into trunkxprint_packagertest_20041217_basexprint_packagertest_20041125_baserel-0-6-1lg3d-rel-0-7-0lg3d-rel-0-6-2lg3d-baseXORG-6_8_2XORG-6_8_1_904XORG-6_8_1_903XORG-6_8_1_902XORG-6_8_1_901XORG-6_8_1XORG-6_8_0XORG-6_7_99_904XORG-6_7_99_903XORG-6_7_99_902XORG-6_7_99_901XORG-6_7_99_2XORG-6_7_99_1XACE-SELINUX-MERGExprint_packagertest_20041217xprint_packagertest_20041125lg3d-masterlg3d-eventlg3d-dev-0-7-1lg3d-dev-0-7-0lg3d-dev-0-6-latestlg3d-dev-0-6-2lg3d-dev-0-6-1-latestlg3d-dev-0-6-1-currentlg3d-dev-0-6-1-1lg3d-dev-0-6-1lg3dXORG-6_8-branchCOMPOSITEWRAPEgbert Eich
2004-03-14Importing vendor version xf86-4_4_99_1 on Sun Mar 14 00:26:39 PST 2004xf86-4_4_99_1Egbert Eich
2004-03-03Importing vendor version xf86-4_4_0 on Wed Mar 3 04:09:24 PST 2004xf86-4_4_0STSF-CURRENTEgbert Eich
2004-02-26readding XFree86's cvs IDsxf86-4_3_99_903Egbert Eich
2004-02-26Importing vendor version xf86-4_3_99_903 on Wed Feb 26 01:21:00 PST 2004Egbert Eich
2003-11-14Initial revisionXORG-RELEASE-1-BASEXEVIE-MERGEXEVIE-BASEXORG-STABLEXINERAMA_2XEVIEKaleb Keithley