strlib.h 760 B

12345678910111213141516171819202122
  1. // Copyright (c) Athena Dev Teams - Licensed under GNU GPL
  2. // For more information, see LICENCE in the main folder
  3. #ifndef _J_STR_LIB_H_
  4. #define _J_STR_LIB_H_
  5. #define J_MAX_MALLOC_SIZE 65535
  6. // String function library.
  7. // code by Jioh L. Jung (ziozzang@4wish.net)
  8. // This code is under license "BSD"
  9. char* jstrescape (char* pt);
  10. char* jstrescapecpy (char* pt,char* spt);
  11. int jmemescapecpy (char* pt,char* spt, int size);
  12. #if !defined(HAVE_mit_thread) && !defined(HAVE_STRTOK_R)
  13. #define strtok_r(s,delim,save_ptr) athena_strtok_r((s),(delim),(save_ptr))
  14. char *athena_strtok_r(char *s1, const char *s2, char **lasts);
  15. #endif
  16. // custom functions
  17. int remove_control_chars(unsigned char *);
  18. char *trim(char *str, const char *delim);
  19. #endif