After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 50209 - Need a G_TYPE_ for non-nul-terminated strings
Need a G_TYPE_ for non-nul-terminated strings
Status: RESOLVED FIXED
Product: glib
Classification: Platform
Component: gobject
1.3.x
Other All
: Normal enhancement
: ---
Assigned To: gtkdev
gtkdev
Depends on:
Blocks:
 
 
Reported: 2000-12-20 23:08 UTC by Havoc Pennington
Modified: 2013-10-25 05:10 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
start at G_TYPE_BYTES, still needs glib-genmarshal.c fixes (6.84 KB, patch)
2001-03-27 23:48 UTC, Owen Taylor
none Details | Review
Second version with glib-genmarshal.c changes (7.83 KB, patch)
2001-03-28 00:37 UTC, Owen Taylor
none Details | Review

Description Havoc Pennington 2000-12-20 23:08:35 UTC
Some signals have string arguments that are not nul-terminated;
instead, a length is passed in. This breaks because G_TYPE_STRING
assumes nul termination and copies the string with g_strdup().
As with boxed types, we need to be able to pass a string to a signal
without copying it; e.g. insert_text can take extremely long strings,
which would be quite a performance hit to copy.
Comment 1 Havoc Pennington 2001-01-29 19:27:55 UTC
Setting all outstanding bugs against 1.3.x to be due for the 2.0.0 milestone;
will go through and move some of them to API freeze milestone and set milestone
to none for punted features.
Comment 2 Havoc Pennington 2001-01-29 19:29:14 UTC
Moving GLib bugs with API keyword to the API freeze milestone
Comment 3 Owen Taylor 2001-03-27 23:48:33 UTC
Created attachment 430 [details] [review]
start at G_TYPE_BYTES, still needs glib-genmarshal.c fixes
Comment 4 Owen Taylor 2001-03-28 00:37:22 UTC
Created attachment 431 [details] [review]
Second version with glib-genmarshal.c changes
Comment 5 Owen Taylor 2001-06-28 16:54:19 UTC
Moved to future milestone due to complete disgareement on ordering -
Tim feels that an ordering incompatible with signals like
::insert_text is necessary, so we'll just have to keep G_TYPE_POINTER
in there for now.
Comment 6 Allison Karlitskaya (desrt) 2013-10-25 05:10:40 UTC
We have G_TYPE_BYTES these days.