Commit Graph

112 Commits

Author SHA1 Message Date
Peter Howkins
a69ed1cf9b libDtHelp: Cov 89366 2018-08-11 00:34:40 +01:00
Peter Howkins
e85dfc66be libDtHelp: Cov 89172 2018-08-11 00:32:39 +01:00
Peter Howkins
e620df0d0d libDtUtil: Cov 88127 2018-08-11 00:31:12 +01:00
Peter Howkins
8982069031 libDtUtil: Cov 88123 2018-08-11 00:30:24 +01:00
Peter Howkins
cb363a5965 libDtHelp: Cov 88084 2018-08-11 00:27:52 +01:00
Peter Howkins
9c2c796d1b libDtHelp: Cov 88527 2018-08-11 00:26:42 +01:00
Peter Howkins
b69319e43c libDtHelp: Cov 88839 2018-08-11 00:25:20 +01:00
Peter Howkins
0e66cfee7f libDtHelp: Cov 89582 2018-08-11 00:24:04 +01:00
Peter Howkins
db779f870e libDtHelp: Cov 87607 2018-08-11 00:21:18 +01:00
Peter Howkins
adb9a3d8cd libDtHelp: Coverity 88440 2018-07-04 01:40:12 +01:00
Peter Howkins
1fb5110337 libDtHelp: 88550 2018-07-04 01:38:14 +01:00
Peter Howkins
a7e09ae1c3 libDtHelp: Coverity 88665 2018-07-04 01:36:03 +01:00
Peter Howkins
9383267ded libDtHelp: Coverity 88906 2018-07-04 01:34:02 +01:00
Peter Howkins
25c12cad4a libDtHelp: Coverity 88813 2018-07-04 01:32:53 +01:00
Peter Howkins
49b69c257a libDtHelp: Coverity 89548 2018-07-04 01:31:19 +01:00
Peter Howkins
045643d4db libDtHelp: Coverity 88776 2018-07-04 01:29:49 +01:00
Jon Trulson
5b5ac72691 lib/DtHelp: remove register keyword 2018-06-27 21:58:04 -06:00
Jon Trulson
2760adaab3 lib/DtHelp/jpeg: remove register keyword 2018-06-27 21:58:04 -06:00
Jon Trulson
e9d0d91cad lib/DtHelp/il: remove register keyword 2018-06-27 21:58:04 -06:00
Peter Howkins
e43dbc5460 libDtHelp: Change to ANSI function definitions 2018-06-28 03:53:31 +01:00
chase
809c3d8bb6 Spelling fixes 2018-05-31 22:23:19 -06:00
Ulrich Wilkens
297b6bd845 Fix warnings on FreeBSD 2018-05-31 22:04:08 -06:00
chase
4f5e7fe5e3 Use POSIX macros for linux 2018-05-24 18:22:55 -06:00
chase
164e695cd0 remove OSF1 support 2018-05-24 14:25:26 -06:00
chase
07900bd93b Remove Unixware and openserver support 2018-05-20 12:13:07 -06:00
chase
8a4f389634 Remove UXPDS support 2018-05-15 20:27:22 -06:00
chase
33d2749ea3 Last of the spelling fixed 2018-04-28 12:36:44 -06:00
chase
6d3a19d8f9 Even more spelling fixed 2018-04-28 12:36:33 -06:00
chase
1fe5a550b2 Fix typo in license headers 2018-04-28 12:30:20 -06:00
chase
07722f5c13 More spelling fixes 2018-04-22 12:15:08 -06:00
Jon Trulson
f4e3cb8327 dthelp/FormatUtils: fix coredump in dthelpgen due to free() of a bad address 2018-04-10 16:30:25 -06:00
Swift Griggs
1fdcd4c93d Patches from pkgsrc-WIP 2016-08-05 11:21:06 -06:00
Peter Howkins
f8f04a5977 libDtHelp: Resolve 11 compiler warnings. 2015-01-14 11:41:38 +00:00
Jon Trulson
17379a3fc0 DtHelp: Coverity (memory corruption, moderate) 2014-12-26 15:50:41 -07:00
Jon Trulson
7887e99477 DtHelp: Coverity (memory corruption, moderate) 2014-12-26 15:49:43 -07:00
Jon Trulson
9751abddff DtHelp: Coverity (memory corruption) 2014-12-26 13:42:23 -07:00
Ulrich Wilkens
01d6c363fa OpenIndiana and Solaris port 2014-10-28 13:40:11 -06:00
Ulrich Wilkens
c3f74eec17 FreeBSD 10 clang port 2014-07-27 12:32:35 -06:00
Peter Tribble
468d576030 initial illumos port 2014-03-22 16:33:11 -06:00
Ulrich Wilkens
2712d5f787 NetBSD port 2014-02-22 19:12:19 -07:00
Ulrich Wilkens
6b0da8f335 Introduction of BSDArchitecture 2013-10-20 16:23:40 -06:00
Ulrich Wilkens
2d08153289 correction of message files 2013-09-15 19:35:53 -06:00
Ulrich Wilkens
a4ab06ac1e lib/DtHelp: added missing include. 2013-07-25 18:29:33 -06:00
Pascal Stumpf
7e0a9517e3 Silence lots of warnings in lib/DtHelp.
* 64bit warnings
* Missing prototypes
* explicit parentheses / brackets

There's still some work to be done, but, as always, it's a start ...
2013-07-22 17:19:13 -06:00
Peter Howkins
21feacd159 libdthelp: Resolve 65 -Wunused-variable warnings 2012-11-09 17:20:46 +00:00
Peter Howkins
cd39eabb18 libdthelp: resolve 46 compiler warnings 2012-10-08 15:34:45 +01:00
Marcin Cieslak
775fb0f0f1 Don't break help with gcc -O2
libDtHelp is unable to read SDL help files
with -ftree-store-ccp optimization which
is enabled by -O2 on gcc 4.2.1.

GifUtils.c and decompress.c didn't work
properly with -ftree-store-ccp enabled.

GifUtils.c was repaired by fixing
those warnings:

GifUtils.c: In function 'create_pixmap':
GifUtils.c:1093: warning: return makes integer from pointer without a cast
GifUtils.c:1110: warning: return makes integer from pointer without a cast
GifUtils.c:1215: warning: return makes integer from pointer without a cast
GifUtils.c: In function 'gif_to_pixmap':
GifUtils.c:1242: warning: return makes integer from pointer without a cast

decompress.c didn't generate warnings, but the
only effect of the -ftree-store-cpp was to introduce
this change:

        addq    $1, %rax
        movq    %rax, (%rbx)
 .L90:
-       cmpl    $157, %edx
+       cmpl    $-99, %edx
        jne     .L86
        movl    8(%rbx), %eax
        subl    $1, %eax

Which corresponds to this source code:

bufioI.h

     57 #define BufFileGet(f)   ((f)->left-- ? *(f)->bufp++ : (*(f)->io) (f))

     42     int     (*io)(/* BufFilePtr f */);

decompress.c
     53 #ifdef NO_UCHAR
     54  typedef char   char_type;
     55 #else
     56  typedef        unsigned char   char_type;
     57 #endif /* UCHAR */
     58
     59 static  char_type magic_header[] = { "\037\235" };      /* 1F 9D */

    131     if ((BufFileGet(f) != (magic_header[0] & 0xFF)) ||
    132         (BufFileGet(f) != (magic_header[1] & 0xFF)))
    133     {
    134         return 0;
    135     }

BufFileGet() returns (int), so the (unsigned char) constants
got promoted to (int) with sign extension; therefore constant
157 decimal (0x9D) became -99 decimal, sign extended
(0xffffff9D), and the comparison was always false.

Tested using:
$ gcc -v
Using built-in specs.
Target: amd64-undermydesk-freebsd
Configured with: FreeBSD/amd64 system compiler
Thread model: posix
gcc version 4.2.1 20070831 patched [FreeBSD]

Running on:
FreeBSD 10.0-CURRENT (r240948M)
built Wed Sep 26 23:33:08 CEST 2012
2012-10-01 18:59:14 -06:00
Frederic Koehler
4773d68153 dthelp: Avoid undefined behaviour in strcpy
Technically strcpy's ranges cannot overlap at all,
although in practice this is usually not an issue.
Does quiet a valgrind warning, however.
2012-09-29 19:21:27 -06:00
Marcin Cieslak
917f7da191 157 warnings: remove -DXK_MISCELLANY from Makefiles
Fixes the following warning:

In file included from ../../../imports/x11/include/X11/Xutil.h:54,
                 from ../../../imports/x11/include/X11/Intrinsic.h:54,
                 from Action.c:64:
../../../imports/x11/include/X11/keysym.h:49:1: warning: "XK_MISCELLANY" redefined
<command-line>: warning: this is the location of the previous definition

<keysym.h> which includes all key symbols and loads <keysymdef.h>
is automaticlly included by the X Toolkit.

This patch removes #include <keysymdef.h> whenever not needed,
and adds #define XK_MISCALLANY in the source code where required.
2012-09-24 18:30:21 -06:00
Jon Trulson
a29fc20957 message catalogs: fix comment lines, also remove linux hack in merge.c
According to the spec, blank lines in message catalogs or lines
beginning with '$ ' are valid comments.

However, there were many cases where lines in the message catalogs
contained just a single '$', without the required space after it.

Under linux, this caused 126766 error lines (in my builds) of the
form:

... unknown directive `': line ignored

This also causes gencat to exit with a non-0 exit code.  Even though
gencat says it ignores the line, it really doesn't.

An early porting change to programs/localized/util/merge.c was made to
ignore this return value on linux.  This hack has now been removed.

Build logs are a lot smaller and cleaner now.
2012-09-03 15:12:57 -06:00