patch-Wnn_jserver_error_c 661 B

12345678910111213141516171819202122232425262728293031
  1. $OpenBSD: patch-Wnn_jserver_error_c,v 1.3 2017/04/29 14:31:40 espie Exp $
  2. --- Wnn/jserver/error.c.orig
  3. +++ Wnn/jserver/error.c
  4. @@ -55,9 +55,10 @@
  5. #include "commonhd.h"
  6. #include "de_header.h"
  7. #include <pwd.h>
  8. +#include <stdlib.h>
  9. +#include <time.h>
  10. +#include <string.h>
  11. -extern int errno;
  12. -
  13. static void my_error(), exit_hand();
  14. void error1();
  15. @@ -91,11 +92,11 @@ static void
  16. my_error(x)
  17. register char *x;
  18. {
  19. - long obakenoQ;
  20. + time_t obakenoQ;
  21. /* struct passed *getpwiuid(); */
  22. if(!noisy)return;
  23. - obakenoQ = time((long *)0);
  24. + obakenoQ = time(NULL);
  25. if(c_c){
  26. #ifdef SYSVR2
  27. fprintf(stderr , "client %s : %s %s errno =%d\n\n" ,