Skip to content

Commit 8f9fa8a

Browse files
authored
Merge pull request #2917 from jayaramcs/ct-3.10.0
OS Account where clause SQL error.
2 parents 5619726 + aaca3d2 commit 8f9fa8a

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

bindings/java/src/org/sleuthkit/datamodel/OsAccountManager.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -794,8 +794,8 @@ OsAccountInstance newOsAccountInstance(long osAccountId, long dataSourceObjId, O
794794
// It's possible that we weren't able to load the account instance because it
795795
// is already in the database but the instance cache was cleared during an account merge.
796796
// Try loading it here and re-adding to the cache.
797-
String whereClause = "tsk_os_account_instances.os_account_obj_id = " + osAccountId
798-
+ "AND tsk_os_account_instances.data_source_obj_id = " + dataSourceObjId;
797+
String whereClause = " tsk_os_account_instances.os_account_obj_id = " + osAccountId
798+
+ " AND tsk_os_account_instances.data_source_obj_id = " + dataSourceObjId;
799799
List<OsAccountInstance> instances = getOsAccountInstances(whereClause);
800800
if (instances.isEmpty()) {
801801
throw new TskCoreException(String.format("Could not get autogen key after row insert or reload instance for OS account instance. OS account object id = %d, data source object id = %d", osAccountId, dataSourceObjId));
@@ -1525,7 +1525,7 @@ List<OsAccountAttribute> getOsAccountAttributes(OsAccount account) throws TskCor
15251525
* @throws TskCoreException
15261526
*/
15271527
public List<OsAccountInstance> getOsAccountInstances(OsAccount account) throws TskCoreException {
1528-
String whereClause = "tsk_os_account_instances.os_account_obj_id = " + account.getId();
1528+
String whereClause = " tsk_os_account_instances.os_account_obj_id = " + account.getId();
15291529
return getOsAccountInstances(whereClause);
15301530
}
15311531

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy