Browse Source

cve-update-db-native: use SQL placeholders instead of format strings

(From OE-Core rev: 91770338f76ef35f3c4eeac216eb9d2b3188e575)

Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Ross Burton 4 years ago
parent
commit
075683d230
1 changed files with 1 additions and 1 deletions
  1. 1 1
      meta/recipes-core/meta/cve-update-db-native.bb

+ 1 - 1
meta/recipes-core/meta/cve-update-db-native.bb

@@ -57,7 +57,7 @@ python do_populate_cve_db() {
             break
 
         # Compare with current db last modified date
-        c.execute("select DATE from META where YEAR = '%d'" % year)
+        c.execute("select DATE from META where YEAR = ?", (year,))
         meta = c.fetchone()
         if not meta or meta[0] != last_modified:
             # Update db with current year json file