InjectLibrary returns -1

c++ / delphi package - dll injection and api hooking
Post Reply
manutai
Posts: 85
Joined: Sun Aug 03, 2008 1:40 am

InjectLibrary returns -1

Post by manutai »

InjectLibrary returns -1, while doing system wide injection. Is it an error or success? What does it signify? Why its not a positive value, if it is a success?
madshi
Site Admin
Posts: 10754
Joined: Sun Mar 21, 2004 5:25 pm

Re: InjectLibrary returns -1

Post by madshi »

By definition 0 is FALSE, everything else in TRUE. You can test this in C++ by doing this:

Code: Select all

if (-1) doSomething();
Post Reply