sxemacs
8 years agoMerge remote-tracking branch 'origin/master' into for-steve
Nelson Ferreira [Wed, 1 Feb 2012 16:15:57 +0000 (11:15 -0500)]
Merge remote-tracking branch 'origin/master' into for-steve

8 years agoMerge branch 'openindie'
Steve Youngs [Tue, 31 Jan 2012 02:34:08 +0000 (12:34 +1000)]
Merge branch 'openindie'

* openindie:
  Fix build on OpenIndiana

8 years agoFix build on OpenIndiana
Steve Youngs [Tue, 31 Jan 2012 02:31:43 +0000 (12:31 +1000)]
Fix build on OpenIndiana

"Fix" is probably too strong a word here, it wasn't really broken in the
first place.  Just a tiny tweak to autogen.sh was the only "fix" needed
here.

This changeset also documents (in PROBLEMS) the missing deps needed to
build SXEmacs on OpenIndiana.

* autogen.sh: Only add the xpg4/bin directory to the $PATH if this
isn't OpenIndiana.

* PROBLEMS: Document build quirks for OpenIndiana.

Signed-off-by: Steve Youngs <steve@sxemacs.org>
8 years agoThe Great Whitespace Cleanup
Steve Youngs [Sat, 28 Jan 2012 08:01:03 +0000 (18:01 +1000)]
The Great Whitespace Cleanup

* whitespace: (24 commits)
  Whitespace cleanup in src [m-z]
  Whitespace cleanup in src [f-l]
  Whitespace cleanup in src [a-e]
  Whitespace cleanup in src/database
  Whitespace cleanup in src/ent
  Whitespace cleanup in src/events
  Whitespace cleanup in src/m
  Whitespace cleanup in src/media
  Whitespace cleanup in src/mem
  Whitespace cleanup in src/mule
  Whitespace cleanup in src/s
  Whitespace cleanup in src/ui
  Whitespace cleanup in src/ui/lwlib
  Whitespace cleanup in src/ui/X11
  Whitespace cleanup in src/ui/TTY
  Whitespace cleanup in tests
  Whitespace cleanup in modules
  Whitespace cleanup in m4
  Whitespace cleanup in lisp
  Whitespace cleanup in lib-src
  ...

8 years agoWhitespace cleanup in src [m-z]
Steve Youngs [Sat, 28 Jan 2012 07:41:50 +0000 (17:41 +1000)]
Whitespace cleanup in src [m-z]

Signed-off-by: Steve Youngs <steve@sxemacs.org>
8 years agoWhitespace cleanup in src [f-l]
Steve Youngs [Sat, 28 Jan 2012 07:27:57 +0000 (17:27 +1000)]
Whitespace cleanup in src [f-l]

Signed-off-by: Steve Youngs <steve@sxemacs.org>
8 years agoWhitespace cleanup in src [a-e]
Steve Youngs [Sat, 28 Jan 2012 07:22:02 +0000 (17:22 +1000)]
Whitespace cleanup in src [a-e]

Signed-off-by: Steve Youngs <steve@sxemacs.org>
8 years agoWhitespace cleanup in src/database
Steve Youngs [Sat, 28 Jan 2012 07:08:21 +0000 (17:08 +1000)]
Whitespace cleanup in src/database

Signed-off-by: Steve Youngs <steve@sxemacs.org>
8 years agoWhitespace cleanup in src/ent
Steve Youngs [Sat, 28 Jan 2012 07:06:29 +0000 (17:06 +1000)]
Whitespace cleanup in src/ent

Signed-off-by: Steve Youngs <steve@sxemacs.org>
8 years agoWhitespace cleanup in src/events
Steve Youngs [Sat, 28 Jan 2012 06:59:05 +0000 (16:59 +1000)]
Whitespace cleanup in src/events

Signed-off-by: Steve Youngs <steve@sxemacs.org>
8 years agoWhitespace cleanup in src/m
Steve Youngs [Sat, 28 Jan 2012 06:54:49 +0000 (16:54 +1000)]
Whitespace cleanup in src/m

Signed-off-by: Steve Youngs <steve@sxemacs.org>
8 years agoWhitespace cleanup in src/media
Steve Youngs [Sat, 28 Jan 2012 06:47:35 +0000 (16:47 +1000)]
Whitespace cleanup in src/media

Signed-off-by: Steve Youngs <steve@sxemacs.org>
8 years agoWhitespace cleanup in src/mem
Steve Youngs [Sat, 28 Jan 2012 06:41:08 +0000 (16:41 +1000)]
Whitespace cleanup in src/mem

Signed-off-by: Steve Youngs <steve@sxemacs.org>
8 years agoWhitespace cleanup in src/mule
Steve Youngs [Sat, 28 Jan 2012 06:39:24 +0000 (16:39 +1000)]
Whitespace cleanup in src/mule

Signed-off-by: Steve Youngs <steve@sxemacs.org>
8 years agoWhitespace cleanup in src/s
Steve Youngs [Sat, 28 Jan 2012 06:36:00 +0000 (16:36 +1000)]
Whitespace cleanup in src/s

Signed-off-by: Steve Youngs <steve@sxemacs.org>
8 years agoWhitespace cleanup in src/ui
Steve Youngs [Sat, 28 Jan 2012 06:20:04 +0000 (16:20 +1000)]
Whitespace cleanup in src/ui

Signed-off-by: Steve Youngs <steve@sxemacs.org>
8 years agoWhitespace cleanup in src/ui/lwlib
Steve Youngs [Sat, 28 Jan 2012 06:06:36 +0000 (16:06 +1000)]
Whitespace cleanup in src/ui/lwlib

Signed-off-by: Steve Youngs <steve@sxemacs.org>
8 years agoWhitespace cleanup in src/ui/X11
Steve Youngs [Sat, 28 Jan 2012 06:01:24 +0000 (16:01 +1000)]
Whitespace cleanup in src/ui/X11

Signed-off-by: Steve Youngs <steve@sxemacs.org>
8 years agoWhitespace cleanup in src/ui/TTY
Steve Youngs [Sat, 28 Jan 2012 05:45:45 +0000 (15:45 +1000)]
Whitespace cleanup in src/ui/TTY

Signed-off-by: Steve Youngs <steve@sxemacs.org>
8 years agoWhitespace cleanup in tests
Steve Youngs [Sat, 28 Jan 2012 04:35:02 +0000 (14:35 +1000)]
Whitespace cleanup in tests

Signed-off-by: Steve Youngs <steve@sxemacs.org>
8 years agoWhitespace cleanup in modules
Steve Youngs [Sat, 28 Jan 2012 04:28:25 +0000 (14:28 +1000)]
Whitespace cleanup in modules

Signed-off-by: Steve Youngs <steve@sxemacs.org>
8 years agoWhitespace cleanup in m4
Steve Youngs [Sat, 28 Jan 2012 04:20:31 +0000 (14:20 +1000)]
Whitespace cleanup in m4

Signed-off-by: Steve Youngs <steve@sxemacs.org>
8 years agoWhitespace cleanup in lisp
Steve Youngs [Sat, 28 Jan 2012 04:16:00 +0000 (14:16 +1000)]
Whitespace cleanup in lisp

Signed-off-by: Steve Youngs <steve@sxemacs.org>
8 years agoWhitespace cleanup in lib-src
Steve Youngs [Sat, 28 Jan 2012 03:00:23 +0000 (13:00 +1000)]
Whitespace cleanup in lib-src

Signed-off-by: Steve Youngs <steve@sxemacs.org>
8 years agoWhitespace cleanup in info
Steve Youngs [Sat, 28 Jan 2012 02:52:19 +0000 (12:52 +1000)]
Whitespace cleanup in info

Signed-off-by: Steve Youngs <steve@sxemacs.org>
8 years agoWhitespace cleanup in etc
Steve Youngs [Sat, 28 Jan 2012 02:17:00 +0000 (12:17 +1000)]
Whitespace cleanup in etc

Signed-off-by: Steve Youngs <steve@sxemacs.org>
8 years agoWhitespace cleanup in contrib
Steve Youngs [Sat, 28 Jan 2012 02:12:08 +0000 (12:12 +1000)]
Whitespace cleanup in contrib

Signed-off-by: Steve Youngs <steve@sxemacs.org>
8 years agoWhitespace cleanup in toplevel dir
Steve Youngs [Sat, 28 Jan 2012 02:08:52 +0000 (12:08 +1000)]
Whitespace cleanup in toplevel dir

Signed-off-by: Steve Youngs <steve@sxemacs.org>
8 years agoMerge branch 'merges'
Steve Youngs [Sat, 28 Jan 2012 00:15:37 +0000 (10:15 +1000)]
Merge branch 'merges'

* merges:
  Conditional definition of HAVE_ALLOCA to avoid meaningless HAVE_ALLOCA redefined warnings...
  Use the real pre-processor var: DEBUG_SXEMACS
  Coverity: Forward NULL: CID 607

8 years agoSlightly better basic type detection.
Nelson Ferreira [Sat, 28 Jan 2012 00:03:34 +0000 (19:03 -0500)]
Slightly better basic type detection.

* m4/sxe-libc.m4 (SXE_CHECK_BASIC_TYPES): Check for int64_t, intptr_t and sizeof float

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoConditional definition of HAVE_ALLOCA to avoid meaningless HAVE_ALLOCA redefined...
Nelson Ferreira [Fri, 27 Jan 2012 22:57:17 +0000 (17:57 -0500)]
Conditional definition of HAVE_ALLOCA to avoid meaningless HAVE_ALLOCA redefined warnings...

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoMerge branch 'for-steve' into njsf-cov
Nelson Ferreira [Fri, 27 Jan 2012 22:47:11 +0000 (17:47 -0500)]
Merge branch 'for-steve' into njsf-cov

8 years agoautogen.sh fix from Nelson
Steve Youngs [Wed, 25 Jan 2012 05:41:59 +0000 (15:41 +1000)]
autogen.sh fix from Nelson

* merges:
  Use head -n1 throughout
  Do not confuse GIT with git (or vice-versa)

8 years agoUse head -n1 throughout
Steve Youngs [Wed, 25 Jan 2012 05:40:11 +0000 (15:40 +1000)]
Use head -n1 throughout

Signed-off-by: Steve Youngs <steve@sxemacs.org>
8 years agoDo not confuse GIT with git (or vice-versa)
Nelson Ferreira [Wed, 25 Jan 2012 04:45:59 +0000 (23:45 -0500)]
Do not confuse GIT with git (or vice-versa)

* autogen.sh: Make sure to only conside one line of git describe,
thus taking care of GIT (http://www.gnu.org/software/git/) being
installed instead of git (http://git-scm.com)

* configure.ac: ditto.

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoMerge branch 'breathing'
Steve Youngs [Wed, 25 Jan 2012 00:21:36 +0000 (10:21 +1000)]
Merge branch 'breathing'

* breathing:
  Be consistent with setting and testing for breathing_space

8 years agoBe consistent with setting and testing for breathing_space
Steve Youngs [Wed, 25 Jan 2012 00:19:53 +0000 (10:19 +1000)]
Be consistent with setting and testing for breathing_space

* src/alloc.c (refill_memory_reserve): Test if breathing_space is
NULL, not zero.
Don't cast the malloc.

* src/alloc.c (garbage_collect_1): Increase breathing_space to,
erm, give us more breathing space.

* src/alloc.c (reinit_alloc_once_early): Set breathing_space to
NULL, not zero.

Signed-off-by: Steve Youngs <steve@sxemacs.org>
8 years agoBuild fix from Sebastian
Steve Youngs [Wed, 25 Jan 2012 00:02:25 +0000 (10:02 +1000)]
Build fix from Sebastian

* merges:
  Summary: fix, make sure ssp actually works before using it Keywords: bldchn diagnostics

8 years agoMerge branch 'bldchn/diag' into next
Sebastian Freundt [Tue, 24 Jan 2012 23:45:50 +0000 (23:45 +0000)]
Merge branch 'bldchn/diag' into next

* bldchn/diag:
  Summary: fix, make sure ssp actually works before using it Keywords: bldchn diagnostics

8 years agoSummary: fix, make sure ssp actually works before using it
Sebastian Freundt [Tue, 24 Jan 2012 23:45:43 +0000 (23:45 +0000)]
Summary: fix, make sure ssp actually works before using it
Keywords: bldchn diagnostics

This changeset hopefully resolves the issue Nelson had with ssp and
-fstack-protector.  Using crystal ball technology and rune readings
it turns out that gcc single-handedly adds -lssp as soon as
-fstack-protector is specified, regardless if it works or exists.

* m4/sxe-compiler.m4 (SXE_STACK_FLAGS): check if ssp works before adding
  -fstack-protector

Signed-off-by: Sebastian Freundt <hroptatyr@fresse.org>
8 years agoBuild fix from Rudi
Steve Youngs [Tue, 24 Jan 2012 12:20:47 +0000 (22:20 +1000)]
Build fix from Rudi

* merges:
  build fix, undeclared XmCR_UNKNOWN

8 years agobuild fix, undeclared XmCR_UNKNOWN
Ruediger Meier [Tue, 24 Jan 2012 11:19:57 +0000 (12:19 +0100)]
build fix, undeclared XmCR_UNKNOWN

This got accidentally broken in 613c762f.

8 years agoChanges from Nelson
Steve Youngs [Tue, 24 Jan 2012 02:33:31 +0000 (12:33 +1000)]
Changes from Nelson

* merges:
  Add a bit more breathing space to alloc
  Cosmetic break
  Empty merge
  compre on by default, no longer experimental

8 years agoAdd a bit more breathing space to alloc
Nelson Ferreira [Mon, 23 Jan 2012 23:53:36 +0000 (18:53 -0500)]
Add a bit more breathing space to alloc

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoBuild chain tweaks from Sebastian
Steve Youngs [Mon, 23 Jan 2012 22:22:26 +0000 (08:22 +1000)]
Build chain tweaks from Sebastian

* merges:
  Summary: minor, provide malldbg multiarg for MALLOC_PERTURB_ Keywords: bldchn diagnostics
  Summary: minor, add stack to --with-error-checking to turn SSP on Keywords: bldchn diagnostics

8 years agoMerge branch 'bldchn/diag' into next
Sebastian Freundt [Mon, 23 Jan 2012 21:45:37 +0000 (21:45 +0000)]
Merge branch 'bldchn/diag' into next

* bldchn/diag:
  Summary: minor, provide malldbg multiarg for MALLOC_PERTURB_ Keywords: bldchn diagnostics
  Summary: minor, add stack to --with-error-checking to turn SSP on Keywords: bldchn diagnostics

8 years agoSummary: minor, provide malldbg multiarg for MALLOC_PERTURB_
Sebastian Freundt [Mon, 23 Jan 2012 21:45:10 +0000 (21:45 +0000)]
Summary: minor, provide malldbg multiarg for MALLOC_PERTURB_
Keywords: bldchn diagnostics

This changeset introduces a multiarg item to the error-checking option
group, named `malldbg', that controls MALLOC_PERTURB_ and friends when
dumping.  This should fix the dumping procedure on MALLOC_PERTURB_
systems as our dumper reacts quite sensitively to that kind of system
hardening.

This changeset contains no additional intelligence to turn it off
automatically, if you see crashes during the dump phase conside
--with-error-checking=nomalldbg.

Whether or not we can persuade (read fix) the dumper code to react more
friendly to this kind of interference is subject to a different patch.

* configure.ac: add `malldbg' to the error-checking multiarg

* m4/sxe-compiler.m4: prepare EXTRA_BATCHENV in case malldbg is off

* src/Makefile.am: extend dumping environment to EXTRA_BATCHENV

Signed-off-by: Sebastian Freundt <hroptatyr@fresse.org>
8 years agoCosmetic break
Nelson Ferreira [Mon, 23 Jan 2012 19:03:28 +0000 (14:03 -0500)]
Cosmetic break

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoEmpty merge
Nelson Ferreira [Mon, 23 Jan 2012 19:01:57 +0000 (14:01 -0500)]
Empty merge

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agocompre on by default, no longer experimental
Nelson Ferreira [Mon, 23 Jan 2012 18:52:52 +0000 (13:52 -0500)]
compre on by default, no longer experimental

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoUse the real pre-processor var: DEBUG_SXEMACS
Nelson Ferreira [Mon, 23 Jan 2012 18:52:12 +0000 (13:52 -0500)]
Use the real pre-processor var: DEBUG_SXEMACS

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoMerge remote-tracking branch 'origin/master' into njsf-cov
Nelson Ferreira [Mon, 23 Jan 2012 09:28:44 +0000 (04:28 -0500)]
Merge remote-tracking branch 'origin/master' into njsf-cov

8 years agoCoverity: Forward NULL: CID 607
Nelson Ferreira [Mon, 23 Jan 2012 09:26:35 +0000 (04:26 -0500)]
Coverity: Forward NULL: CID 607

* lib-src/etags.c (regex_tag_multiline): Really fix Forward NULL.

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoSummary: minor, add stack to --with-error-checking to turn SSP on
Sebastian Freundt [Sun, 22 Jan 2012 11:42:14 +0000 (11:42 +0000)]
Summary: minor, add stack to --with-error-checking to turn SSP on
Keywords: bldchn diagnostics

This changeset fixes a potential stack bashing in the mapfam permutation
code by inserting proper break statements where they belong.  This could
be one of the reasons of bug #135 and it's yet to be shown that it fixes
anything (other than pleasing coverity).

* configure.ac: add `stack' to the error-checking multiarg

* m4/sxe-compiler.m4: check for -fstack-protector and link with libssp

Signed-off-by: Sebastian Freundt <hroptatyr@fresse.org>
8 years agoFix ase-interval from Nelson
Steve Youngs [Sat, 21 Jan 2012 06:44:57 +0000 (16:44 +1000)]
Fix ase-interval from Nelson

* merges:
  Fix crash in _ase_interval_union_boundary. Only fini tmp when ur->next becomes tmp->next

8 years agoFix crash in _ase_interval_union_boundary. Only fini tmp when ur->next becomes tmp...
Nelson Ferreira [Sat, 21 Jan 2012 06:22:07 +0000 (01:22 -0500)]
Fix crash in _ase_interval_union_boundary. Only fini tmp when ur->next becomes tmp->next

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity fixes from Nelson
Steve Youngs [Sat, 21 Jan 2012 05:36:53 +0000 (15:36 +1000)]
Coverity fixes from Nelson

* merges:
  Coverity: Assert side effect: CID 2
  Coverity: Checked return: CID 10
  Coverity: Checked return: CID 11
  Coverity: Checked return: CID 12
  Coverity: Char IO: CID 7
  Coverity: No effect: CID 134
  Coverity: Overrun static: CID 137, 136
  Coverity: Overrun static: CID 139
  Coverity: Overrun static: CID 141
  Coverity: Resource leak: CID 178
  Coverity: Resource leak: CID 180
  Coverity: Resource leak: CID 181
  Coverity: Resource leak: CID 181
  Coverity: Resource leak: CID 183
  Coverity: Resource Leak: CID 184
  Coverity: Resource Leak: CID 185
  Coverity: Forward NULL: CID 605
  Coverity: Missing return: CID 606

8 years agoCoverity: Assert side effect: CID 2
Nelson Ferreira [Sat, 21 Jan 2012 04:44:33 +0000 (23:44 -0500)]
Coverity: Assert side effect: CID 2

* src/extents.c (gap_array_delete_marker): Remove unnecessary
volatile (we don't multithread so we should have this be
interrupted. If at some point we make multi-threaded SXEmacs, this
should be protected by some barrier.

* src/extents.c (gap_array_delete_all_markers): Ditto.

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Checked return: CID 10
Nelson Ferreira [Sat, 21 Jan 2012 04:39:47 +0000 (23:39 -0500)]
Coverity: Checked return: CID 10

* lib-src/hexl.c (main): signal intent to ignore read char

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Checked return: CID 11
Nelson Ferreira [Sat, 21 Jan 2012 04:39:00 +0000 (23:39 -0500)]
Coverity: Checked return: CID 11

* lib-src/make-docfile.c (scan_lisp_file): Signal intent to ignore
read char.

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Checked return: CID 12
Nelson Ferreira [Sat, 21 Jan 2012 04:38:14 +0000 (23:38 -0500)]
Coverity: Checked return: CID 12

* modules/ase/ase-interval.c (_ase_interval_union_item_fini):
Signal intention to ignore the return value of decref.

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Char IO: CID 7
Nelson Ferreira [Sat, 21 Jan 2012 04:36:38 +0000 (23:36 -0500)]
Coverity: Char IO: CID 7

* lib-src/make-docfile.c (read_lisp_symbol): Proper handling of
cast for getc...

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: No effect: CID 134
Nelson Ferreira [Sat, 21 Jan 2012 04:26:55 +0000 (23:26 -0500)]
Coverity: No effect: CID 134

* src/ui/TTY/event-tty.c (emacs_tty_next_event): Change the loop
variable to int to properly map the type of descriptors.

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Overrun static: CID 137, 136
Nelson Ferreira [Sat, 21 Jan 2012 04:24:45 +0000 (23:24 -0500)]
Coverity: Overrun static: CID 137, 136

* src/mule/mule-charset.h (CHARSET_BY_ATTRIBUTES): Do paranoid
bounds checking...

* src/mule/mule-charset.h (REP_BYTES_BY_FIRST_BYTE): Make sure to
not dereference in fatal crash scenario where assert flows through...

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Overrun static: CID 139
Nelson Ferreira [Sat, 21 Jan 2012 04:18:37 +0000 (23:18 -0500)]
Coverity: Overrun static: CID 139

* src/dumper.c (pdump_register_object): Fix of-by-one boundary and
return after abort for fatal crash scenario.

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Overrun static: CID 141
Nelson Ferreira [Sat, 21 Jan 2012 04:13:10 +0000 (23:13 -0500)]
Coverity: Overrun static: CID 141

* src/ui/imgproc.c (get_histogram): Introduce paranoid histogram

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Resource leak: CID 178
Nelson Ferreira [Sat, 21 Jan 2012 04:04:34 +0000 (23:04 -0500)]
Coverity: Resource leak: CID 178

* lib-src/etags.c (regex_tag_multiline): Make it clear a non-null
name was allocated in substitute and always free it :)

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Resource leak: CID 180
Nelson Ferreira [Sat, 21 Jan 2012 03:57:44 +0000 (22:57 -0500)]
Coverity: Resource leak: CID 180

* lib-src/movemail.c (lock_dot): free the memory

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Resource leak: CID 181
Nelson Ferreira [Sat, 21 Jan 2012 03:55:04 +0000 (22:55 -0500)]
Coverity: Resource leak: CID 181

* lib-src/ootags.c (Erlang_functions): free the memory

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Resource leak: CID 181
Nelson Ferreira [Sat, 21 Jan 2012 03:53:29 +0000 (22:53 -0500)]
Coverity: Resource leak: CID 181

* lib-src/ootags.c (Erlang_functions): xfree the memory

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Resource leak: CID 183
Nelson Ferreira [Sat, 21 Jan 2012 03:52:05 +0000 (22:52 -0500)]
Coverity: Resource leak: CID 183

* lib-src/yow.c (yow): Free the memory...

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Resource Leak: CID 184
Nelson Ferreira [Sat, 21 Jan 2012 03:49:06 +0000 (22:49 -0500)]
Coverity: Resource Leak: CID 184

* modules/ase/ase-interval.c (_ase_interval_union_boundary):
Properly get rid of the interval.

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Resource Leak: CID 185
Nelson Ferreira [Sat, 21 Jan 2012 03:44:28 +0000 (22:44 -0500)]
Coverity: Resource Leak: CID 185

* modules/ase/ase-interval.c (_ase_subtract_intr_intr): Properly
get rid of the interval.

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Forward NULL: CID 605
Nelson Ferreira [Sat, 21 Jan 2012 03:15:40 +0000 (22:15 -0500)]
Coverity: Forward NULL: CID 605

* src/ui/X11/event-Xt.c (Xt_timeout_callback): Just return in case
of fatal crash scenario.

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Missing return: CID 606
Nelson Ferreira [Sat, 21 Jan 2012 03:13:23 +0000 (22:13 -0500)]
Coverity: Missing return: CID 606

* src/ui/window.c (window_display_buffer): Return NULL for the
fatal crash scenario.

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoconfigure fix plus mapfam fix from Sebastian
Steve Youngs [Sat, 21 Jan 2012 02:16:00 +0000 (12:16 +1000)]
configure fix plus mapfam fix from Sebastian

* merges:
  Summary: fix, add missing break statements in mapfam permutation code Keywords: fix bug 135
  Summary: fix, properly expand OG_MULTIARG_ITEM indirections Keywords: bldchn

8 years agoMerge branch 'bug/135' into next
Sebastian Freundt [Sat, 21 Jan 2012 00:03:25 +0000 (00:03 +0000)]
Merge branch 'bug/135' into next

* bug/135:
  Summary: fix, add missing break statements in mapfam permutation code Keywords: fix bug 135

8 years agoSummary: fix, add missing break statements in mapfam permutation code
Sebastian Freundt [Sat, 21 Jan 2012 00:03:13 +0000 (00:03 +0000)]
Summary: fix, add missing break statements in mapfam permutation code
Keywords: fix bug 135

This changeset fixes a potential stack bashing in the mapfam permutation
code by inserting proper break statements where they belong.  This could
be one of the reasons of bug #135 and it's yet to be shown that it fixes
anything (other than pleasing coverity).

* src/map.c (__perm_nseq): no switch fallthrough, insert breaks

Signed-off-by: Sebastian Freundt <hroptatyr@fresse.org>
8 years agoMerge branch 'bldchn' into next
Sebastian Freundt [Fri, 20 Jan 2012 23:58:21 +0000 (23:58 +0000)]
Merge branch 'bldchn' into next

* bldchn:
  Summary: fix, properly expand OG_MULTIARG_ITEM indirections Keywords: bldchn

8 years agoSummary: fix, properly expand OG_MULTIARG_ITEM indirections
Sebastian Freundt [Fri, 20 Jan 2012 23:58:10 +0000 (23:58 +0000)]
Summary: fix, properly expand OG_MULTIARG_ITEM indirections
Keywords: bldchn

This changeset expands the explanations of multiarg items in option
groups properly (again), m4_text_wrap (and AS_HELP_STRING) fail to
evaluate arguments that come from the temporary redefinition of
OG_MULTIARG_ITEM.

* m4/sxe-option-groups.m4: mimic AS_HELP_STRING in temporary expansion
  of OG_MULTIARG_ITEM

Signed-off-by: Sebastian Freundt <hroptatyr@fresse.org>
8 years agoCoverity updates/fixes from Nelson
Steve Youngs [Fri, 20 Jan 2012 23:13:36 +0000 (09:13 +1000)]
Coverity updates/fixes from Nelson

* merges:
  Avoid warnings
  Coverity: Forward NULL: CID 32
  Coverity: Forward NULL: CID 33
  Coverity: Forward NULL: CID 34
  Coverity: Forward NULL: CID 35
  Coverity: Forward NULL: CID 37
  Coverity: Forward NULL: CID 38
  Coverity: Forward NULL: CID 39
  Coverity: Forward NULL: CID 42, 41
  Coverity: Forward NULL: CID 44, 43, 36
  Coverity: Forward NULL: CID 48
  Coverity: Forward NULL: CID 49
  Coverity: Forward NULL: CID 50
  Coverity: Forward NULL: CID 51
  Coverity: Forward NULL: CID 54, 53, 52
  Fix additional transcoding assertions
  Coverity: Negative returns: CID 121
  Update link to newest compface in INSTALL
  Coverity: Missing return: CID 604

8 years agoAvoid warnings
Nelson Ferreira [Fri, 20 Jan 2012 18:11:39 +0000 (13:11 -0500)]
Avoid warnings

* src/ui/X11/device-x.c (x_get_visual_depth): Avoid uninitialized
return in fatal crash.

* src/ui/X11/frame-x.c (x_set_frame_properties): Change warn to
message, just in case...

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Forward NULL: CID 32
Nelson Ferreira [Fri, 20 Jan 2012 17:54:38 +0000 (12:54 -0500)]
Coverity: Forward NULL: CID 32

* src/extents.c (extent_list_delete_marker): Make sure p is not
dereference if NULL even in case of fatal crash.

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Forward NULL: CID 33
Nelson Ferreira [Fri, 20 Jan 2012 17:52:29 +0000 (12:52 -0500)]
Coverity: Forward NULL: CID 33

* src/alloc.c (build_string): Make sure to only dereference str if
not NULL even in fatal crash case.

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Forward NULL: CID 34
Nelson Ferreira [Fri, 20 Jan 2012 17:50:42 +0000 (12:50 -0500)]
Coverity: Forward NULL: CID 34

* src/mem/ralloc.c (r_alloc_free): Make sure bloc is only
dereferenced if not NULL even in fatal crash case.

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Forward NULL: CID 35
Nelson Ferreira [Fri, 20 Jan 2012 17:49:52 +0000 (12:49 -0500)]
Coverity: Forward NULL: CID 35

* src/mem/ralloc.c (r_re_alloc): Make sure bloc is only
dereferenced if not NULL even in fatal crash case.

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Forward NULL: CID 37
Nelson Ferreira [Fri, 20 Jan 2012 17:47:31 +0000 (12:47 -0500)]
Coverity: Forward NULL: CID 37

* src/fns.c (concat): Make sure args_mse is not dereferenced in
case of NULL even in case of fatal crash.

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Forward NULL: CID 38
Nelson Ferreira [Fri, 20 Jan 2012 17:45:25 +0000 (12:45 -0500)]
Coverity: Forward NULL: CID 38

* src/doprnt.c (emacs_doprnt_1): Make sure to only dereference
largs if NULL even in case of a '*' format qualifier.

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Forward NULL: CID 39
Nelson Ferreira [Fri, 20 Jan 2012 17:44:04 +0000 (12:44 -0500)]
Coverity: Forward NULL: CID 39

* lib-src/etags.c (regex_tag_multiline): Make sure to abort if name is NULL

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Forward NULL: CID 42, 41
Nelson Ferreira [Fri, 20 Jan 2012 17:43:14 +0000 (12:43 -0500)]
Coverity: Forward NULL: CID 42, 41

* src/ui/redisplay-output.c (redisplay_clear_region): Make sure to
return from function for case of fatal crash after abort.

* src/ui/redisplay.c (regenerate_window): Ditto.

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Forward NULL: CID 44, 43, 36
Nelson Ferreira [Fri, 20 Jan 2012 17:41:16 +0000 (12:41 -0500)]
Coverity: Forward NULL: CID 44, 43, 36

* src/ui/window.c (window_display_buffer): Make sure t is only
dereference if not NULL even in case of fatal crash.

* src/ui/window.c (set_window_display_buffer): Ditto.
* src/ui/window.c (window_display_lines): Ditto.

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Forward NULL: CID 48
Nelson Ferreira [Fri, 20 Jan 2012 17:39:01 +0000 (12:39 -0500)]
Coverity: Forward NULL: CID 48

* src/ui/X11/device-x.c (x_get_visual_depth): make sure vi_out is
only dereference is not NULL, even in fatal crash scenario.

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Forward NULL: CID 49
Nelson Ferreira [Fri, 20 Jan 2012 17:35:49 +0000 (12:35 -0500)]
Coverity: Forward NULL: CID 49

* src/ui/lwlib/lwlib.c (instantiate_widget_instance): Make sure
function is not dereferenced as NULL even in fatal crash case.

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Forward NULL: CID 50
Nelson Ferreira [Fri, 20 Jan 2012 17:34:43 +0000 (12:34 -0500)]
Coverity: Forward NULL: CID 50

* src/ui/lwlib/lwlib-Xlw.c (xlw_update_tab_control): Make sure cur
is not dereference when NULL.

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Forward NULL: CID 51
Nelson Ferreira [Fri, 20 Jan 2012 17:33:00 +0000 (12:33 -0500)]
Coverity: Forward NULL: CID 51

* src/ui/X11/event-Xt.c (Xt_timeout_callback): Make sure possible
NULL are not dereference, even in fatal crash scenario.

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Forward NULL: CID 54, 53, 52
Nelson Ferreira [Fri, 20 Jan 2012 17:31:22 +0000 (12:31 -0500)]
Coverity: Forward NULL: CID 54, 53, 52

* src/ui/X11/xgccache.c (gc_cache_lookup): Make sure not to derefence possible NULL pointers.

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoMerge branch 'for-steve' into njsf-cov
Nelson Ferreira [Fri, 20 Jan 2012 17:28:55 +0000 (12:28 -0500)]
Merge branch 'for-steve' into njsf-cov

8 years agoFix additional transcoding assertions
Nelson Ferreira [Fri, 20 Jan 2012 17:28:05 +0000 (12:28 -0500)]
Fix additional transcoding assertions

* src/buffer.h (TO_EXTERNAL_FORMAT): Remove the bad assert (ie not
valid in all conditions).
* src/buffer.h (TO_INTERNAL_FORMAT): Ditto.

* src/buffer.h (DFC_SOURCE_DATA_TO_ARGS): Do the proper assert to
the source conversion.
* src/buffer.h (DFC_SOURCE_C_STRING_TO_ARGS): Ditto.
* src/buffer.h (DFC_SOURCE_LISP_OPAQUE_TO_ARGS): Ditto.

* src/buffer.h (DFC_ALLOCA_USE_CONVERTED_DATA): Do the proper assert
to the converted data.
* src/buffer.h (DFC_MALLOC_USE_CONVERTED_DATA): Ditto.
* src/buffer.h (DFC_C_STRING_ALLOCA_USE_CONVERTED_DATA): Ditto.
* src/buffer.h (DFC_C_STRING_MALLOC_USE_CONVERTED_DATA): Ditto.
* src/buffer.h (DFC_LISP_STRING_USE_CONVERTED_DATA): Ditto.
* src/buffer.h (DFC_LISP_OPAQUE_USE_CONVERTED_DATA): Ditto.

* src/alloc.c (ALLOCATE_FIXED_TYPE): Make sure to detect failed
allocations.
* src/alloc.c (ALLOCATE_ATOMIC_FIXED_TYPE): Ditto.
* src/alloc.c (make_uninit_string): Make sure the uninit string is
valid after construction.

* src/opaque.c (make_opaque): Make sure to detect failed
allocations even in the fatal crash scenario.

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoCoverity: Negative returns: CID 121
Nelson Ferreira [Fri, 20 Jan 2012 15:38:36 +0000 (10:38 -0500)]
Coverity: Negative returns: CID 121

* src/ui/TTY/objects-tty.c (tty_font_spec_matches_charset):
Actually fix the negative return issue, for the fatal crash case.

Signed-off-by: Nelson Ferreira <nelson.ferreira@ieee.org>
8 years agoMerge branch 'for-steve' into njsf-cov
Nelson Ferreira [Fri, 20 Jan 2012 15:36:01 +0000 (10:36 -0500)]
Merge branch 'for-steve' into njsf-cov