]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit
gdb: fix ui-style regex initializing order
authorZENG Hao <c@cyano.cn>
Fri, 18 Apr 2025 22:41:28 +0000 (06:41 +0800)
committerTom Tromey <tromey@adacore.com>
Tue, 22 Apr 2025 14:46:00 +0000 (08:46 -0600)
commitdadaf42c653f4eba6ada9d09d087253e8c97ecd7
treef674910d0c39182089e2d3c8b428afaa591ce028
parent236fb2b56e6367159aa5457d99428a751ff37cdd
gdb: fix ui-style regex initializing order

This fixes a crash on Windows NT 4.0, where windows-nat failed dynamic loading
some Win32 functions and print a warning message with styled string, which
depends on ui-style regex. By using `compiled_regex` constructor, the regex is
guaranteed to be initialized before `_initialize_xxx` functions.

Approved-By: Tom Tromey <tom@tromey.com>
gdb/ui-style.c