29 lines
617 B
Text
29 lines
617 B
Text
|
--- evdns.c.orig Tue Apr 20 20:35:13 2010
|
||
|
+++ evdns.c Tue Apr 20 20:36:31 2010
|
||
|
@@ -47,12 +47,14 @@
|
||
|
#ifndef DNS_USE_GETTIMEOFDAY_FOR_ID
|
||
|
#ifndef DNS_USE_OPENSSL_FOR_ID
|
||
|
#ifndef DNS_USE_FTIME_FOR_ID
|
||
|
+#ifndef DNS_USE_ARC4RANDOM_FOR_ID
|
||
|
#error Must configure at least one id generation method.
|
||
|
#error Please see the documentation.
|
||
|
#endif
|
||
|
#endif
|
||
|
#endif
|
||
|
#endif
|
||
|
+#endif
|
||
|
|
||
|
/* #define _POSIX_C_SOURCE 200507 */
|
||
|
#define _GNU_SOURCE
|
||
|
@@ -1080,6 +1082,10 @@ default_transaction_id_fn(void)
|
||
|
*/
|
||
|
abort();
|
||
|
}
|
||
|
+#endif
|
||
|
+
|
||
|
+#ifdef DNS_USE_ARC4RANDOM_FOR_ID
|
||
|
+ trans_id = arc4random() & 0xffff;
|
||
|
#endif
|
||
|
return trans_id;
|
||
|
}
|