PATCH 21.5
Missing typecasts break current C++ build. This patch fixes it.
I'll commit Friday, if nobody objects.
src/ChangeLog addition:
2007-08-15 Marcus Crestani <crestani(a)xemacs.org>
* database.c (dbm_map): Add typecast.
* database.c (dbm_get): Add typecast.
* gc.c (gc_state_type): Declare type.
* objects-tty.c (tty_find_charset_font): Add typecast.
* objects-xlike-inc.c (count_hyphens): Add typecast.
* objects-xlike-inc.c (endif): Add typecast.
g++-xemacs-21.5 source patch:
Diff command: cvs -q diff -u
Files affected: src/objects-xlike-inc.c
===================================================================
RCS src/objects-tty.c
===================================================================
RCS src/gc.c
===================================================================
RCS src/database.c
===================================================================
RCS
Index: src/database.c
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/src/database.c,v
retrieving revision 1.39
diff -u -r1.39 database.c
--- src/database.c 11 Dec 2006 19:44:56 -0000 1.39
+++ src/database.c 15 Aug 2007 11:14:22 -0000
@@ -281,9 +281,9 @@
keydatum = dbm_nextkey (db->dbm_handle))
{
valdatum = dbm_fetch (db->dbm_handle, keydatum);
- key = make_ext_string (keydatum.dptr, keydatum.dsize,
+ key = make_ext_string ((Extbyte *) keydatum.dptr, keydatum.dsize,
db->coding_system);
- val = make_ext_string (valdatum.dptr, valdatum.dsize,
+ val = make_ext_string ((Extbyte *) valdatum.dptr, valdatum.dsize,
db->coding_system);
call2 (func, key, val);
}
@@ -300,7 +300,7 @@
valdatum = dbm_fetch (db->dbm_handle, keydatum);
return (valdatum.dptr
- ? make_ext_string (valdatum.dptr, valdatum.dsize,
+ ? make_ext_string ((Extbyte *) valdatum.dptr, valdatum.dsize,
db->coding_system)
: Qnil);
}
Index: src/gc.c
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/src/gc.c,v
retrieving revision 1.7
diff -u -r1.7 gc.c
--- src/gc.c 14 Aug 2007 18:58:16 -0000 1.7
+++ src/gc.c 15 Aug 2007 11:14:23 -0000
@@ -107,10 +107,10 @@
};
#ifndef ERROR_CHECK_GC
-struct
+typedef struct gc_state_type
{
enum gc_phase phase;
-} gc_state;
+} gc_state_type;
#else /* ERROR_CHECK_GC */
enum gc_stat_id
{
@@ -122,7 +122,7 @@
GC_STAT_COUNT /* has to be last */
};
-struct
+typedef struct gc_state_type
{
enum gc_phase phase;
double n_gc[GC_STAT_COUNT];
@@ -134,8 +134,10 @@
double dequeued2[GC_STAT_COUNT];
double finalized[GC_STAT_COUNT];
double freed[GC_STAT_COUNT];
-} gc_state;
+} gc_state_type;
#endif /* ERROR_CHECK_GC */
+
+gc_state_type gc_state;
#define GC_PHASE gc_state.phase
#define GC_SET_PHASE(p) GC_PHASE = p
Index: src/objects-tty.c
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/src/objects-tty.c,v
retrieving revision 1.20
diff -u -r1.20 objects-tty.c
--- src/objects-tty.c 15 Aug 2007 11:06:10 -0000 1.20
+++ src/objects-tty.c 15 Aug 2007 11:14:23 -0000
@@ -374,7 +374,7 @@
if (strchr ((const char *) fontname, '/'))
{
if (tty_font_spec_matches_charset (XDEVICE (device), charset, 0,
- font, 0, -1, 0))
+ font, 0, -1, initial))
return font;
return Qnil;
}
Index: src/objects-xlike-inc.c
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/src/objects-xlike-inc.c,v
retrieving revision 1.6
diff -u -r1.6 objects-xlike-inc.c
--- src/objects-xlike-inc.c 22 Feb 2007 16:19:44 -0000 1.6
+++ src/objects-xlike-inc.c 15 Aug 2007 11:14:23 -0000
@@ -61,7 +61,7 @@
const Ibyte *new_hyphening;
for (hyphen_count = 0;
- NULL != (new_hyphening = memchr((const void *)hyphening, '-', length));
+ NULL != (new_hyphening = (Ibyte *) memchr((const void *)hyphening, '-',
length));
hyphen_count++)
{
++new_hyphening;
@@ -786,7 +786,7 @@
for (j = 0; j < registries_len; ++j)
{
if (0 == qxestrcasecmp(XSTRING_DATA(XVECTOR_DATA(registries)[j]),
- FALLBACK_ASCII_REGISTRY))
+ (Ibyte *) FALLBACK_ASCII_REGISTRY))
{
have_latin1 = 1;
break;
--
Marcus
_______________________________________________
XEmacs-Patches mailing list
XEmacs-Patches(a)xemacs.org
http://calypso.tux.org/cgi-bin/mailman/listinfo/xemacs-patches