summaryrefslogtreecommitdiff
path: root/libs/libevent/src
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2016-03-23 12:19:19 +0000
committerGeorge Hazan <george.hazan@gmail.com>2016-03-23 12:19:19 +0000
commitfa9e319eab3d1a379db437239e28f2553af5b1b4 (patch)
treec9f07d4b22f4659f852d29714ebd6e51920767d7 /libs/libevent/src
parent04f670ac098e07fe1cf5770d0d77e77f3b756a6b (diff)
unified project for libevent
git-svn-id: http://svn.miranda-ng.org/main/trunk@16525 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'libs/libevent/src')
-rw-r--r--libs/libevent/src/arc4random.cxx (renamed from libs/libevent/src/arc4random.c)14
-rw-r--r--libs/libevent/src/evutil_rand.c2
-rw-r--r--libs/libevent/src/stdafx.cxx2
-rw-r--r--libs/libevent/src/stdafx.h2
4 files changed, 12 insertions, 8 deletions
diff --git a/libs/libevent/src/arc4random.c b/libs/libevent/src/arc4random.cxx
index a2338e692a..40d6642e58 100644
--- a/libs/libevent/src/arc4random.c
+++ b/libs/libevent/src/arc4random.cxx
@@ -52,8 +52,10 @@
#ifndef ARC4RANDOM_NO_INCLUDES
#include "evconfig-private.h"
#ifdef _WIN32
+#include <Windows.h>
#include <wincrypt.h>
#include <process.h>
+#include <stdint.h>
#else
#include <fcntl.h>
#include <unistd.h>
@@ -91,10 +93,9 @@ static pid_t arc4_stir_pid;
static int arc4_count;
static int arc4_seeded_ok;
-static inline unsigned char arc4_getbyte(void);
+static unsigned char arc4_getbyte(void);
-static inline void
-arc4_init(void)
+static void arc4_init(void)
{
int n;
@@ -104,8 +105,7 @@ arc4_init(void)
rs.j = 0;
}
-static inline void
-arc4_addrandom(const unsigned char *dat, int datlen)
+static void arc4_addrandom(const unsigned char *dat, int datlen)
{
int n;
unsigned char si;
@@ -422,7 +422,7 @@ arc4_stir_if_needed(void)
}
}
-static inline unsigned char
+static unsigned char
arc4_getbyte(void)
{
unsigned char si, sj;
@@ -436,7 +436,7 @@ arc4_getbyte(void)
return (rs.s[(si + sj) & 0xff]);
}
-static inline unsigned int
+static unsigned int
arc4_getword(void)
{
unsigned int val;
diff --git a/libs/libevent/src/evutil_rand.c b/libs/libevent/src/evutil_rand.c
index 046a14b07a..0402772db3 100644
--- a/libs/libevent/src/evutil_rand.c
+++ b/libs/libevent/src/evutil_rand.c
@@ -131,7 +131,7 @@ static void *arc4rand_lock;
#define ARC4RANDOM_NORANDOM
#define ARC4RANDOM_NOUNIFORM
-#include "./arc4random.c"
+#include "./arc4random.cxx"
#ifndef EVENT__DISABLE_THREAD_SUPPORT
int
diff --git a/libs/libevent/src/stdafx.cxx b/libs/libevent/src/stdafx.cxx
new file mode 100644
index 0000000000..0fb604da7c
--- /dev/null
+++ b/libs/libevent/src/stdafx.cxx
@@ -0,0 +1,2 @@
+
+#include "stdafx.h" \ No newline at end of file
diff --git a/libs/libevent/src/stdafx.h b/libs/libevent/src/stdafx.h
new file mode 100644
index 0000000000..d78b7834c8
--- /dev/null
+++ b/libs/libevent/src/stdafx.h
@@ -0,0 +1,2 @@
+
+// just a stub \ No newline at end of file