Skip to content
This repository has been archived by the owner on Oct 26, 2022. It is now read-only.

Commit

Permalink
Fix a mangled UPDATE query, from the REF column removal.
Browse files Browse the repository at this point in the history
  • Loading branch information
vjorlikowski committed Jul 20, 2012
1 parent 15b930f commit 9147df2
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/main/java/orca/imageproxy/SqliteDLDatabase.java
Original file line number Diff line number Diff line change
Expand Up @@ -75,16 +75,16 @@ public synchronized String checkDownloadList(String signature, boolean mark, Str
try {
if (rs.next()) {
path = rs.getString("FILEPATH");
newActiveRef = rs.getInt("ACTIVEREF") + 1;
newActiveRef = rs.getInt("ACTIVEREF") + 1;
}
}
finally { rs.close(); }
if (mark) {
if (path != null) {
query = "UPDATE " + filestable +
", ACTIVEREF = " + newActiveRef +
", LASTREF = " + System.currentTimeMillis() +
" WHERE SIGNATURE = " + dbString(signature);
query = "UPDATE " + filestable + " SET " +
"ACTIVEREF=" + newActiveRef + ", " +
"LASTREF=" + System.currentTimeMillis() + " " +
"WHERE SIGNATURE=" + dbString(signature);
}
else {
// SIGNATURE, FILEPATH, FILESIZE, ACTIVEREF, SEEDING, STATUS,
Expand Down

0 comments on commit 9147df2

Please sign in to comment.