my_nosys.h 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. /* Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved.
  2. This program is free software; you can redistribute it and/or modify
  3. it under the terms of the GNU General Public License as published by
  4. the Free Software Foundation; version 2 of the License.
  5. This program is distributed in the hope that it will be useful,
  6. but WITHOUT ANY WARRANTY; without even the implied warranty of
  7. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  8. GNU General Public License for more details.
  9. You should have received a copy of the GNU General Public License
  10. along with this program; if not, write to the Free Software
  11. Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */
  12. /*
  13. Header to remove use of my_functions in functions where we need speed and
  14. where calls to posix functions should work
  15. */
  16. #ifndef _my_nosys_h
  17. #define _my_nosys_h
  18. #ifdef __cplusplus
  19. extern "C" {
  20. #endif
  21. #ifndef __MY_NOSYS__
  22. #define __MY_NOSYS__
  23. #ifndef HAVE_STDLIB_H
  24. #include <malloc.h>
  25. #endif
  26. #undef my_read
  27. #undef my_write
  28. #undef my_seek
  29. #define my_read(a,b,c,d) my_quick_read(a,b,c,d)
  30. #define my_write(a,b,c,d) my_quick_write(a,b,c)
  31. extern size_t my_quick_read(File Filedes,uchar *Buffer,size_t Count,
  32. myf myFlags);
  33. extern size_t my_quick_write(File Filedes,const uchar *Buffer,size_t Count);
  34. #endif /* __MY_NOSYS__ */
  35. #ifdef __cplusplus
  36. }
  37. #endif
  38. #endif