On 14-June-2022 06:43, Bram Moolenaar wrote:
Patch 8.2.5084
Problem: When the GUI shows a dialog tests get stuck.
Solution: Add the --gui-dialog-file argument.
Files: runtime/doc/starting.txt, src/Make_mvc.mak, src/gui.c, src/main.c,
src/message.c, src/os_mswin.c, src/proto/gui.pro,
src/proto/main.pro, src/structs.h, src/testdir/Make_dos.mak,
src/testdir/Make_ming.mak, src/testdir/Makefile,
src/testdir/runtest.vim, src/testdir/shared.vim
After this patch mingw64 (gcc 12.1) spits out this warning:
<snip>
gcc -c -I. -Iproto -DWIN32 -DWINVER=0x0603 -D_WIN32_WINNT=0x0603
-DHAVE_PATHDEF -DFEAT_NORMAL -DHAVE_STDINT_H -D__USE_MINGW_ANSI_STDIO
-pipe -march=native -Wall -O3 -fomit-frame-pointer -freg-struct-return
-fpie -fPIE -DFEAT_GUI_MSWIN -DFEAT_CLIPBOARD os_mswin.c -o
gobjnative/os_mswin.oos_mswin.c: In function 'display_errors':
os_mswin.c:681:61: warning: pointer targets in passing argument 2 of
'gui_dialog_log' differ in signedness [-Wpointer-sign]
681 | if (!gui_dialog_log((char_u *)"Errors", p))
| ^
| |
| char *
In file included from proto.h:278,
from vim.h:2255,
from os_mswin.c:16:
proto/gui.pro:70:43: note: expected 'char_u *' {aka 'unsigned char *'}
but argument is of type 'char *'
70 | int gui_dialog_log(char_u *title, char_u *message);
| ~~~~~~~~^~~~~~~
</snip>
The attached patch tries to fix it.
Cheers
John
--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups "vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to vim_dev+unsubscr...@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/vim_dev/ce924c87-9ed8-9043-fd47-99e896950ac4%40internode.on.net.
--- os_mswin.c.orig 2022-06-14 06:49:16.421594200 +1000
+++ os_mswin.c 2022-06-14 07:02:23.343442700 +1000
@@ -664,7 +664,7 @@
display_errors(void)
{
# ifdef FEAT_GUI
- char *p;
+ char_u *p;
# ifdef VIMDLL
if (gui.in_use || gui.starting)
@@ -673,7 +673,7 @@
if (error_ga.ga_data != NULL)
{
// avoid putting up a message box with blanks only
- for (p = (char *)error_ga.ga_data; *p; ++p)
+ for (p = (char_u *)error_ga.ga_data; *p; ++p)
if (!isspace(*p))
{
// Only use a dialog when not using --gui-dialog-file: