+2013-12-17 Eli Zaretskii <eliz@gnu.org>
+
+ * w32term.c (w32_initialize): Declare the argument of
+ set_user_model as const.
+
+ * w32menu.c <MessageBoxW_Proc>: Fix argument declarations.
+ (w32_menu_show): Constify some arguments passed to MessageBox.
+
+ * w32uniscribe.c (uniscribe_font_driver): Use LISP_INITIALLY_ZERO
+ to initialize Lisp objects.
+
+ * w32font.c (w32font_driver): Use LISP_INITIALLY_ZERO to
+ initialize Lisp objects.
+
+ * frame.c (x_set_frame_parameters) [HAVE_X_WINDOWS]: Declare and
+ use variables used only on X under that condition.
+
+ * fileio.c (Fcopy_file) [!WINDOWSNT]: Don't declare on Windows
+ variables not used there.
+
2013-12-16 Paul Eggert <eggert@cs.ucla.edu>
Fix problems with CANNOT_DUMP and EMACSLOADPATH.
entries (depending on how Emacs was built). */)
(Lisp_Object file, Lisp_Object newname, Lisp_Object ok_if_already_exists, Lisp_Object keep_time, Lisp_Object preserve_uid_gid, Lisp_Object preserve_extended_attributes)
{
- int ifd, ofd;
- int n;
- char buf[16 * 1024];
- struct stat st, out_st;
+ struct stat out_st;
Lisp_Object handler;
struct gcpro gcpro1, gcpro2, gcpro3, gcpro4;
ptrdiff_t count = SPECPDL_INDEX ();
#endif
#ifdef WINDOWSNT
int result;
+#else
+ int ifd, ofd;
+ int n;
+ char buf[16 * 1024];
+ struct stat st;
#endif
encoded_file = encoded_newname = Qnil;
Lisp_Object *values;
ptrdiff_t i, p;
bool left_no_change = 0, top_no_change = 0;
+#ifdef HAVE_X_WINDOWS
bool icon_left_no_change = 0, icon_top_no_change = 0;
+#endif
bool size_changed = 0;
struct gcpro gcpro1, gcpro2;
/* If one of the icon positions was not set, preserve or default it. */
if (! TYPE_RANGED_INTEGERP (int, icon_left))
{
+#ifdef HAVE_X_WINDOWS
icon_left_no_change = 1;
+#endif
icon_left = Fcdr (Fassq (Qicon_left, f->param_alist));
if (NILP (icon_left))
XSETINT (icon_left, 0);
}
if (! TYPE_RANGED_INTEGERP (int, icon_top))
{
+#ifdef HAVE_X_WINDOWS
icon_top_no_change = 1;
+#endif
icon_top = Fcdr (Fassq (Qicon_top, f->param_alist));
if (NILP (icon_top))
XSETINT (icon_top, 0);
struct font_driver w32font_driver =
{
- 0, /* Qgdi */
+ LISP_INITIALLY_ZERO, /* Qgdi */
0, /* case insensitive */
w32font_get_cache,
w32font_list,
IN LPCMENUITEMINFOA);
typedef int (WINAPI * MessageBoxW_Proc) (
IN HWND window,
- IN WCHAR *text,
- IN WCHAR *caption,
+ IN const WCHAR *text,
+ IN const WCHAR *caption,
IN UINT type);
#ifdef NTGUI_UNICODE
{
/* Create a new pane. */
Lisp_Object pane_name, prefix;
- char *pane_string;
+ const char *pane_string;
pane_name = AREF (menu_items, i + MENU_ITEMS_PANE_NAME);
prefix = AREF (menu_items, i + MENU_ITEMS_PANE_PREFIX);
/* Use Unicode if possible, so any language can be displayed. */
if (unicode_message_box)
{
- WCHAR *text, *title;
+ WCHAR *text;
+ const WCHAR *title;
USE_SAFE_ALLOCA;
if (STRINGP (temp))
}
else
{
- char *text, *title;
+ const char *text, *title;
/* Fall back on ANSI message box, but at least use system
encoding so questions representable by the system codepage
w32_initialize (void)
{
HANDLE shell;
- HRESULT (WINAPI * set_user_model) (wchar_t * id);
+ HRESULT (WINAPI * set_user_model) (const wchar_t * id);
baud_rate = 19200;
\f
struct font_driver uniscribe_font_driver =
{
- 0, /* Quniscribe */
+ LISP_INITIALLY_ZERO, /* Quniscribe */
0, /* case insensitive */
w32font_get_cache,
uniscribe_list,