Skip to content

Commit

Permalink
Move definition of Dyninst::ThrIDToTid into common/dyntypes.h
Browse files Browse the repository at this point in the history
59ddf22 in 2009, this function was changed to always just return an int-like representation of 'id'.
  • Loading branch information
hainest committed Nov 6, 2023
1 parent cf4dc13 commit 1154f49
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 13 deletions.
2 changes: 1 addition & 1 deletion common/h/dyntypes.h
Expand Up @@ -106,7 +106,7 @@ namespace Dyninst
#endif
#endif

int ThrIDToTid(Dyninst::THR_ID id);
inline int ThrIDToTid(Dyninst::THR_ID id) { return id; }
}

namespace Dyninst
Expand Down
12 changes: 0 additions & 12 deletions common/src/Types.C
Expand Up @@ -61,15 +61,3 @@ char *Address_str (Address addr)
snprintf(_addrstr[i],19,"0x%016lX",(unsigned long)addr);
return (_addrstr[i]);
}


int ThrIDToTid(Dyninst::THR_ID id)
{
#if defined(os_windows)
// This is vista-only; for the time being, we'll return the handle as a dword
// return GetThreadId(id);
return (unsigned long) id;
#else
return (int) id;
#endif
}

0 comments on commit 1154f49

Please sign in to comment.