[Spice-devel] [spice-gtk 1/3] Send Zenkaku_Hankaku key in JP keyboard

Takao Fujiwara tfujiwar at redhat.com
Fri Apr 15 09:13:33 UTC 2016


It seems my debug log of libgdk-win32-2.0-0.dll caused a conflicted IO and SEGV.
After I deleted my debug log, I no longer encounter SEGV so now ImmDisableIME.patch is not necessary.

Thanks,
Fujiwara

On 04/12/16 20:08, Takao Fujiwara-san wrote:
> I mean ImmDisableIME.patch should be used as a workaround.
> It's hard to get why SEGV happens because my build environment is brew scratch-build but not local.
>
> Program received signal SIGSEGV, Segmentation fault.
> [Switching to Thread 1000.0x858]
> 0x000007fefd551abb in msvcrt!_flsbuf () from C:\Windows\system32\msvcrt.dll
> (gdb) where
> #0  0x000007fefd551abb in msvcrt!_flsbuf ()
>     from C:\Windows\system32\msvcrt.dll
> #1  0x000000000022f3fe in ?? ()
> Backtrace stopped: previous frame inner to this frame (corrupt stack?)
>
> When change Ja MS-IME to US with Alt+Shift or MS-IME to JP with Ctrl+Shift, the SEGV happens.
>
> I added the following debug flags in mingw-spice-gtk.spec but cannot get the stacks:
> +%global optflags -g
> +%global __os_install_post :
>
> I mean when IME is switched, WM_INPUTLANGCHANGE is called in gdk_event_translate().
> But ImmDisableIME.patch can disable to switch IMEs and WM_INPUTLANGCHANGE is not called in gdk_event_translate() and SEGV does not happen.
>
> On 04/11/16 20:10, Frediano Ziglio-san wrote:
>>>
>>> Please note the internal ImmDisableIME.patch needs to be disabled to get the
>>> WM_INPUTLANGCHANGE signal with mouse but no ImmDisableIME.patch causes a
>>> SEGV with Ctrl+Shift or Alt+Shift.
>>>
>>
>> Is not clear what you are suggesting with this.
>>
>> Should ImmDisableIME.patch be used or not? Why it SEGV?
>> How do you capture WM_INPUTLANGCHANGE message?
>>
>> Frediano
>>
>>
>>> On 04/06/16 15:42, Takao Fujiwara-san wrote:
>>>> Zenkaku_Hankaku key has the different virtual-key codes between WM_KEYDOWN
>>>> and WM_KEYUP and MapVirtualKey() cannot get the scancode from virtual-key
>>>> code of WM_KEYDOWN (VK_DBE_DBCSCHAR) and spice-gtk didn't send the key
>>>> press events and caused the desktop freeze with unlimited key release
>>>> events.
>>>>
>>>> The fix is to get the scancode from virtual-key code of WM_KEYUP
>>>> (VK_DBE_SBCSCHAR) and Zenkaku_Hankaku key works fine.
>>>>
>>>> Alt + Zenkaku_Hankaku key also has the different virtual-key code and
>>>> MapVirtualKey() cannot get the scancode from the virtual-key and
>>>> spice-gtk didn't send the key press events and Alt+Zenkaku_Hankaku
>>>> could not be used.
>>>>
>>>> The fix is to get the scancode from virtual-key code of Zenkaku_Hankaku key
>>>> (VK_DBE_SBCSCHAR).
>>>>
>>>> VK_CAPITAL, VK_DBE_ROMAN are also applied the similar fixes.
>>>> ---
>>>>    src/spice-widget-priv.h |  1 +
>>>>    src/spice-widget.c      | 78
>>>>    +++++++++++++++++++++++++++++++++++++++++++++++--
>>>>    2 files changed, 77 insertions(+), 2 deletions(-)
>>>
>>> _______________________________________________
>>> Spice-devel mailing list
>>> Spice-devel at lists.freedesktop.org
>>> https://lists.freedesktop.org/mailman/listinfo/spice-devel
>>>
>>
>
> _______________________________________________
> Spice-devel mailing list
> Spice-devel at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/spice-devel



More information about the Spice-devel mailing list