changeset: 5460:4486ba63476b
user: Jeff Sparkes <jsparkes(a)gmail.com>
date: Sun Apr 17 16:27:02 2011 -0400
files: src/ChangeLog src/device-tty.c
description:
Fix compile issues for C89 compilers. Use log() instead of log2().
diff -r aa78b0b0b289 -r 4486ba63476b src/ChangeLog
--- a/src/ChangeLog Sun Apr 17 11:14:38 2011 +0100
+++ b/src/ChangeLog Sun Apr 17 16:27:02 2011 -0400
@@ -1,3 +1,8 @@
+2011-04-17 Jeff Sparkes <jsparkes(a)gmail.com>
+
+ * device-tty.c (tty_device_system_metrics): Fix compile issues for
+ C89 compilers. Use log() instead of log2().
+
2011-04-04 Aidan Kehoe <kehoea(a)parhasard.net>
* fns.c (count_with_tail):
diff -r aa78b0b0b289 -r 4486ba63476b src/device-tty.c
--- a/src/device-tty.c Sun Apr 17 11:14:38 2011 +0100
+++ b/src/device-tty.c Sun Apr 17 16:27:02 2011 -0400
@@ -197,7 +197,11 @@
return Fcons (make_int (CONSOLE_TTY_DATA (con)->width),
make_int (CONSOLE_TTY_DATA (con)->height));
case DM_num_bit_planes:
- return make_int (log2 (CONSOLE_TTY_DATA (con)->colors));
+ {
+ EMACS_INT l2 = (EMACS_INT) (log (CONSOLE_TTY_DATA (con)->colors)
+ / log (2));
+ return make_int (l2);
+ }
case DM_num_color_cells:
return make_int (CONSOLE_TTY_DATA (con)->colors);
default: /* No such device metric property for TTY devices */
_______________________________________________
XEmacs-Patches mailing list
XEmacs-Patches(a)xemacs.org
http://lists.xemacs.org/mailman/listinfo/xemacs-patches