https://sourceware.org/bugzilla/show_bug.cgi?id=17759
Bug ID: 17759 Summary: windres should support to generate string tables with zero-terminated strings Product: binutils Version: unspecified Status: NEW Severity: normal Priority: P2 Component: binutils Assignee: unassigned at sourceware dot org Reporter: mity at morous dot org Win32 API function LoadString() allows to get read-only pointer into the resource data instead of copying the string into provided buffer. (Application can trigger this behavior when using zero as the last argument of the function.) In this case, it is very useful if the string in the resource table is already zero-terminated so application can work with it using the plethora of API functions which expect zero-terminated (unicode) strings. RC.EXE has an option '/n' to request this. There is no similar option for windres which would do the same. As a workaround, the *.RC script can specify the zero terminators explicitly, e.g.: STRINGTABLE BEGIN IDS_FOO "foo\0" IDS_BAR "bar\0" END Unfortunately unlike windres, RC.EXE by default removes the explicitly specified zero terminators. In order to get the zero-terminated strings in both RC.EXE and windres, it is needed to use the explicit terminators and also specify /n option for RC.EXE. That's quite fragile and I see that as very inconvenient. -- You are receiving this mail because: You are on the CC list for the bug. _______________________________________________ bug-binutils mailing list bug-binutils@gnu.org https://lists.gnu.org/mailman/listinfo/bug-binutils