Skip to content

GitLab

  • Menu
Projects Groups Snippets
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • L libXt
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 0
    • Issues 0
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 2
    • Merge requests 2
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Packages & Registries
    • Packages & Registries
    • Container Registry
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • xorg
  • lib
  • libXt
  • Issues
  • #2

Closed
Open
Created Oct 25, 2005 by Bugzilla Migration User@bugzilla-migration

the typedef in X11/Intrinsic.h for Arg does not qualify the name field with const

Submitted by Andrew J. Schorr

Assigned to Jeremy Huddleston Sequoia

Link to original bug (#4875)

Description

In X11/Intrinsic.h, we have this:

typedef char *String;

typedef struct { String name; XtArgVal value; } Arg, *ArgList;

As a result, when the XtSetArg macro is used to populate one of these structures, it is often the case that a constant string (e.g. 'const char *') is assigned to the name field. Since name does not have the const qualifier, a compiler warning is issued.

Is there any reason not to use 'const char *' for the name field? I cannot see why any code would have a reason to modify the name string...

Assignee
Assign to
Time tracking