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 570367 - GtkStockItem members should be const char *
GtkStockItem members should be const char *
Status: RESOLVED WONTFIX
Product: gtk+
Classification: Platform
Component: Widget: Other
3.5.x
Other Linux
: Normal trivial
: ---
Assigned To: gtk-bugs
gtk-bugs
Depends on:
Blocks:
 
 
Reported: 2009-02-03 14:14 UTC by Christian Persch
Modified: 2014-03-13 05:29 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
[PATCH] Bug 570367 – GtkStockItem members should be const char * (512 bytes, patch)
2009-02-03 14:15 UTC, Christian Persch
none Details | Review

Description Christian Persch 2009-02-03 14:14:45 UTC
+++ This bug was initially created as a clone of Bug #565665 +++

It's currently char *.  This causes warnings in code like:

  const GtkStockItem my_stock_items[] = {
    { "my-stock", N_("MyStock"), 0, 0, "my-domain" },
  };

with -Wwrite-strings. Since one is not expected to modify these members, they should be changed to const. We made a similar change in glib recently; it shouldn't cause any problems.
Comment 1 Christian Persch 2009-02-03 14:15:09 UTC
Created attachment 127841 [details] [review]
[PATCH] Bug 570367 – GtkStockItem members should be const char *

 gtk/gtkstock.h |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)
Comment 2 Christian Persch 2009-07-07 12:45:02 UTC
Ping? Can we get this for 2.18 ?
Comment 3 André Klapper 2012-05-07 16:46:02 UTC
Still in 3.5