\section{block\_\-random.c File Reference}
\label{block__random_8c}\index{block_random.c@{block\_\-random.c}}
Part of libcomm: contains {\bf block\_\-random}() {\rm (p.\,\pageref{block__random_8c_a0})}. 


{\tt \#include $<$stdio.h$>$}\par
{\tt \#include $<$stdlib.h$>$}\par
\subsection*{Functions}
\begin{CompactItemize}
\item 
char $\ast$ {\bf block\_\-random} (char $\ast$buf, int size)
\begin{CompactList}\small\item\em Get random numbers/bytes.\item\end{CompactList}\end{CompactItemize}


\subsection{Detailed Description}
Part of libcomm: contains {\bf block\_\-random}() {\rm (p.\,\pageref{block__random_8c_a0})}.





\subsection{Function Documentation}
\index{block_random.c@{block\_\-random.c}!block_random@{block\_\-random}}
\index{block_random@{block\_\-random}!block_random.c@{block\_\-random.c}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}char$\ast$ block\_\-random (char $\ast$ {\em buf}, int {\em size})}\label{block__random_8c_a0}


Get random numbers/bytes.

This function read random numbers/bytes from /dev/urandom and stort this bytes in a buffer.\begin{Desc}
\item[Parameters: ]\par
\begin{description}
\item[{\em 
buf}](char $\ast$) in which the bytes will be stored. If this parameter is equal to NULL dynamic memory will be allocated.\item[{\em 
size}]an integer, specifies ths size of the buffer (the number of the random bytes). WARNING: If buf is not equal to null, n$\ast$(size) bytes will be stored in this buffer without any check of ths size of this buf.\end{description}
\end{Desc}
\begin{Desc}
\item[Returns: ]\par
(char $\ast$) a pointer to the buffer in which the random bytes are stored. \end{Desc}
