Closed (fixed)
Project:
Util
Version:
6.x-2.x-dev
Component:
Code
Priority:
Critical
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
21 Sep 2008 at 10:52 UTC
Updated:
2 Oct 2009 at 16:50 UTC
Jump to comment: Most recent file
Underscore is a SQL wildcard that actually represents any single character, so util_uninstall() may delete all variables starting with 'util'.
This line in util_uninstall():
db_query("DELETE FROM {variable} WHERE name LIKE '%s%%'", 'util_');
Would have to be replace into something like this:
db_query("DELETE FROM {variable} WHERE name LIKE '%s%%'", 'util\_');
Here, underscore is escaped with a backslash so it is treated by the SQL server as a literal character, not a wildcard character.
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | util.install.patch | 376 bytes | markus_petrux |
Comments
Comment #1
markus_petrux commentedSetting to critical as it may delete data that belongs to other modules.
Comment #2
markus_petrux commentedThe patch
Comment #3
nancydruSomewhere along the line, this was committed. Thanks.