- Make the package compile for i386
- Make the pAddr arg for DivertRecv() optional - Make the i386 user binaries compatible with an amd64 driver. (useful for projects not yet ported to amd64)
This commit is contained in:
@@ -14,6 +14,12 @@
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
!IF "$(_BUILDARCH)" == "x86"
|
||||
CPU=i386
|
||||
!ELSE
|
||||
CPU=$(_BUILDARCH)
|
||||
!ENDIF
|
||||
|
||||
TARGETNAME=webfilter
|
||||
TARGETTYPE=PROGRAM
|
||||
TARGETPATH=..\..\install
|
||||
@@ -21,7 +27,7 @@ TARGETLIBS=\
|
||||
$(SDK_LIB_PATH)\setupapi.lib \
|
||||
$(SDK_LIB_PATH)\user32.lib \
|
||||
$(SDK_LIB_PATH)\ws2_32.lib \
|
||||
$(TARGETPATH)\$(_BUILDARCH)\divert.lib
|
||||
$(TARGETPATH)\$(CPU)\divert.lib
|
||||
UMTYPE=console
|
||||
UMENTRY=main
|
||||
USE_MSVCRT=1
|
||||
|
||||
@@ -88,7 +88,7 @@ const char block_data[] =
|
||||
* Prototypes
|
||||
*/
|
||||
static void PacketInit(PPACKET packet);
|
||||
static int UrlCompare(const void *a, const void *b);
|
||||
static int __cdecl UrlCompare(const void *a, const void *b);
|
||||
static int UrlMatch(PURL urla, PURL urlb);
|
||||
static PBLACKLIST BlackListInit(void);
|
||||
static void BlackListInsert(PBLACKLIST blacklist, PURL url);
|
||||
@@ -101,7 +101,7 @@ static BOOL BlackListPayloadMatch(PBLACKLIST blacklist, char *data,
|
||||
/*
|
||||
* Entry.
|
||||
*/
|
||||
int main(int argc, char **argv)
|
||||
int __cdecl main(int argc, char **argv)
|
||||
{
|
||||
HANDLE handle;
|
||||
DIVERT_ADDRESS addr;
|
||||
@@ -536,7 +536,7 @@ static BOOL BlackListPayloadMatch(PBLACKLIST blacklist, char *data, UINT16 len)
|
||||
/*
|
||||
* URL comparison.
|
||||
*/
|
||||
static int UrlCompare(const void *a, const void *b)
|
||||
static int __cdecl UrlCompare(const void *a, const void *b)
|
||||
{
|
||||
PURL urla = *(PURL *)a;
|
||||
PURL urlb = *(PURL *)b;
|
||||
|
||||
Reference in New Issue
Block a user