setup.c 669 B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. /* markdown: a C implementation of John Gruber's Markdown markup language.
  2. *
  3. * Copyright (C) 2007 David L Parsons.
  4. * The redistribution terms are provided in the COPYRIGHT file that must
  5. * be distributed with this source code.
  6. */
  7. #include "config.h"
  8. #include <stdio.h>
  9. #include <string.h>
  10. #include <stdarg.h>
  11. #include <stdlib.h>
  12. #include <time.h>
  13. #include <ctype.h>
  14. #include "cstring.h"
  15. #include "markdown.h"
  16. #include "amalloc.h"
  17. #include "tags.h"
  18. static int need_to_initrng = 1;
  19. void
  20. mkd_initialize()
  21. {
  22. if ( need_to_initrng ) {
  23. need_to_initrng = 0;
  24. INITRNG(time(0));
  25. }
  26. }
  27. void DESTRUCTOR
  28. mkd_shlib_destructor()
  29. {
  30. mkd_deallocate_tags();
  31. }