Skip to content

fix: use Database.Format for SQL escaping instead of g_hDB.Escape - #98

Open
Rushaway wants to merge 1 commit into
darkerz7:masterfrom
srcdslab:upstream-pr/sql-format-escaping
Open

fix: use Database.Format for SQL escaping instead of g_hDB.Escape#98
Rushaway wants to merge 1 commit into
darkerz7:masterfrom
srcdslab:upstream-pr/sql-format-escaping

Conversation

@Rushaway

Copy link
Copy Markdown
Contributor

What

Use Database.Format() instead of manually calling g_hDB.Escape() on each
name buffer before building the query with FormatEx(), in
entwatch_logs_manager.sp.

Database.Format() escapes %s arguments automatically, so the extra
per-parameter Escape call + buffer (sz*_Name) is no longer needed. This
removes a driver/threading touchpoint per logged event and simplifies the
three DB handlers (Item_Handler, Admin_Eban_Handler, Admin_Other_Handler).

Behaviour is unchanged: the same values are escaped and inserted.

Notes

Database.Format escapes %s arguments automatically, avoiding a manual
call+buffer per parameter and the extra driver/threading touchpoints
from calling Escape directly.
@Rushaway

Rushaway commented Sep 7, 2026

Copy link
Copy Markdown
Contributor Author

@darkerz7 Can it be merged ? 🙏

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.

1 participant