
#include<stdio.h>
#include<string.h>
#include<unistd.h>
#include<sys/socket.h>
#include<netinet/in.h>
#include<pthread.h>
#include<stdlib.h>

#include"zither.h"
#include<almemsys/almemsys.h>


/*
int fd_outopen(char *, char *);
*/





/*----------------- LOG_OUT OPEN -------------------*/
int fd_outopen(char * log_filename, FILE * fp)
{
int fd;

if((fp=fopen(log_filename, "a+"))==NULL){ 
   fprintf(stderr,"fd_outopen(): CONNECT FILE NOT OPEN %s\n",log_filename);
   fd = 2;
   }
else {
   fd = fileno(fp);
   }

return(fd);
}




