Skip to content

Commit

Permalink
Tracker: Fix integer overflow
Browse files Browse the repository at this point in the history
CID1108329
  • Loading branch information
jscipione committed Jul 18, 2014
1 parent 1e22816 commit b8bcb08
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/kits/tracker/VirtualDirectoryManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -224,11 +224,13 @@ class VirtualDirectoryManager::RootInfo {
if (error != B_OK)
return error;

bigtime_t fileTime = st.st_mtim.tv_sec * 1000000
+ st.st_mtim.tv_nsec / 1000;
bigtime_t fileTime = st.st_mtim.tv_sec;
fileTime *= 1000000;
fileTime += st.st_mtim.tv_nsec / 1000;
if (fileTime == fFileTime) {
if (_changed != NULL)
*_changed = false;

return B_OK;
}

Expand Down

0 comments on commit b8bcb08

Please sign in to comment.