Skip to content

res: Major cleanup#806

Merged
selvanair merged 3 commits intoOpenVPN:masterfrom
flichtenheld:res-cleanup
Apr 14, 2026
Merged

res: Major cleanup#806
selvanair merged 3 commits intoOpenVPN:masterfrom
flichtenheld:res-cleanup

Conversation

@flichtenheld
Copy link
Copy Markdown
Member

There are many, many strings that are not used since a decade or more. Do a general cleanup.

Note: cleanup is incomplete. So created as a draft PR.

Comment thread openvpn-gui-res.h
#define IDS_LANGUAGE_NAME 1650

/* Win32 Service Related */
/* historic: #define IDS_ERR_OPEN_SCMGR_ADMIN 1701 */
Copy link
Copy Markdown
Collaborator

@selvanair selvanair Apr 2, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Last time when we removed some such defines, the consensus was to keep them commented out to avoid reuse (see #80 ). I do not personally feel that is necessary (i.e., reuse is fine), but just clarifying the origin of such comments, in case anyone cares to preserve them.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think these numbers are ever transmitted somewhere, are they? They are only used by the compiler? So I think it should be perfectly safe to reuse them.

@flichtenheld flichtenheld force-pushed the res-cleanup branch 3 times, most recently from 5a04334 to b428ceb Compare April 13, 2026 14:35
@flichtenheld flichtenheld marked this pull request as ready for review April 13, 2026 14:35
@flichtenheld flichtenheld requested a review from selvanair April 13, 2026 14:35
There are many, many strings that are not used since
a decade or more. Do a general cleanup.

Adds the script used to do the cleanup as res/cleanup_res_ids.sh

Note that the script does not do actually remove anything
(unless you enable some code that is commented out).
All ids were checked manually before removal.

Signed-off-by: Frank Lichtenheld <frank@lichtenheld.com>
Signed-off-by: Frank Lichtenheld <frank@lichtenheld.com>
Didn't cause any issues so far, but make sure we do
not match the wrong ID if one name is the prefix of
another.

Signed-off-by: Frank Lichtenheld <frank@lichtenheld.com>
@flichtenheld flichtenheld requested review from cron2 and uddr April 14, 2026 12:18
Copy link
Copy Markdown
Collaborator

@selvanair selvanair left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wow, this is some cleanup! Looks good.

A future enhancement could be to extend the script to also look for missing entries in non-English resource files.

@selvanair selvanair merged commit bcfc1d4 into OpenVPN:master Apr 14, 2026
10 checks passed
@flichtenheld flichtenheld deleted the res-cleanup branch April 16, 2026 13:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants