Skip to content

Commit

Permalink
Made windows that have an empty exe name collect under the root
Browse files Browse the repository at this point in the history
Before they were collected under a (null) node.
  • Loading branch information
aardappel committed Nov 28, 2015
1 parent fa4ff01 commit 889cc98
Showing 1 changed file with 4 additions and 9 deletions.
13 changes: 4 additions & 9 deletions src/timercallback.h
Original file line number Diff line number Diff line change
Expand Up @@ -105,16 +105,11 @@ VOID CALLBACK timerfunc(HWND hwnd, UINT uMsg, UINT_PTR idEvent, DWORD dwTime)
title[MAXSTR - 1] = 0;
}

std::string s = exename[0] ? exename : "(null)";
if (url[0]) s += " - ";
std::string s = exename;
if (url[0] && s[0]) s += " - ";
s + url;
if (title[0]) s += " - ";
if (title[0] && s[0]) s += " - ";
s += title;

// char buf[MAXSTR];
// sprintf_s(buf, MAXSTR, "%s%s%s%s%s", exename[0] ? exename : "(null)", url[0] ? " - " : "", url, title[0] ? " - "
// : "", title);
// buf[MAXSTR-1] = 0;

addtodatabase((char *)s.c_str(), st, idletime, 0);
if (s[0]) addtodatabase((char *)s.c_str(), st, idletime, 0);
};

0 comments on commit 889cc98

Please sign in to comment.