updates
[silc.git] / lib / silccrypt / silcrng.c
index f68c1b806c0d59c195865f5a4008ee4c9070d046..7bed81e138e9997fd34e502a42ce24e969f516a4 100644 (file)
@@ -28,6 +28,7 @@
 
 #include "silcincludes.h"
 
+#ifndef WIN32
 #ifdef HAVE_GETSID
 extern pid_t getsid (pid_t __pid);
 #endif
@@ -35,6 +36,7 @@ extern pid_t getsid (pid_t __pid);
 #ifdef HAVE_GETPGID
 extern pid_t getpgid (pid_t __pid);
 #endif
+#endif
 
 #undef SILC_RNG_DEBUG
 /*#define SILC_RNG_DEBUG*/
@@ -348,7 +350,7 @@ static void silc_rng_exec_command(SilcRng rng, char *command)
   pclose(fd);
   
   /* Add the buffer into random pool */
-  silc_rng_add_noise(rng, buf, strlen(buf));
+  silc_rng_add_noise(rng, buf, i);
   memset(buf, 0, sizeof(buf));
 #endif
 }