fixed casts in alternate functions.

This commit is contained in:
TLINDEN
2013-12-19 12:31:04 +01:00
parent 89b83dda12
commit 3a107841bb

View File

@@ -72,7 +72,7 @@ static inline u_int32_t arc4random() {
} }
static inline void arc4random_buf(void *buf, size_t nbytes) { static inline void arc4random_buf(void *buf, size_t nbytes) {
randombytes(buf, nbytes); randombytes((unsigned char*)buf, nbytes);
} }
@@ -119,7 +119,7 @@ int vasprintf(char **ret, const char *format, va_list args) {
int count = vsnprintf(NULL, 0, format, args); int count = vsnprintf(NULL, 0, format, args);
if (count >= 0) { if (count >= 0) {
char* buffer = malloc(count + 1); char* buffer = (char *)malloc(count + 1);
if (buffer != NULL) { if (buffer != NULL) {
count = vsnprintf(buffer, count + 1, format, copy); count = vsnprintf(buffer, count + 1, format, copy);
if (count < 0) if (count < 0)