gpt4 book ai didi

c - 运行 GTK+ 应用程序时出现 X 错误

转载 作者:行者123 更新时间:2023-11-30 16:04:42 25 4
gpt4 key购买 nike

我编写了一个 GTK+ 应用程序,但在运行它时遇到以下 X Window 错误:

    The program 'TestApp' received an X Window System error.    This probably reflects a bug in the program.    The error was 'BadMatch (invalid parameter attributes)'.      (Details: serial 222 error_code 8 request_code 2 minor_code 0)      (Note to programmers: normally, X errors are reported asynchronously;       that is, you will receive the error a while after causing it.       To debug your program, run it with the --sync command line       option to change this behavior. You can then get a meaningful       backtrace from your debugger if you break on the gdk_x_error() function.)

导致此错误的原因可能是什么?我用 C 语言编写了这个应用程序。

最佳答案

我会尝试按照建议进行操作:使用 --sync cmd 选项运行应用程序并在调试器中启动它,这样您就可以看到哪一行导致了错误。

关于c - 运行 GTK+ 应用程序时出现 X 错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/2665331/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com