Skip to content
Permalink
Browse files
Fixes some compiler issues on AIX (
  • Loading branch information
montywi committed Feb 8, 2022
1 parent df02de6 commit 88fb89a
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
@@ -31,7 +31,7 @@ extern ulong my_time_to_wait_for_lock;
#include <signal.h>
#ifdef HAVE_SIGHANDLER_T
#define sig_return sighandler_t
#elif defined(SOLARIS) || defined(__sun) || defined(__APPLE__) || defined(__FreeBSD__)
#elif defined(SOLARIS) || defined(__sun) || defined(__APPLE__) || defined(__FreeBSD__) || defined(_AIX)
typedef void (*sig_return)(int); /* Returns type from signal */
#else
typedef void (*sig_return)(void); /* Returns type from signal */
@@ -324,7 +324,7 @@ int my_addr_resolve(void *ptr, my_addr_loc *loc)
for the base program. This is depending on if the compilation is
done with PIE or not.
*/
addr_offset= info.dli_fbase;
addr_offset= (void*) info.dli_fbase;
#ifndef __PIE__
if (strcmp(info.dli_fname, my_progname) == 0 &&
addr_resolve((void*) my_addr_resolve, loc) == 0 &&
@@ -23,6 +23,7 @@

#ifndef MAIN

#if defined(__APPLE__) || defined(__FreeBSD__) || defined(__linux__) || defined(__sun) || defined(_WIN32)
static my_bool memcpy_and_test(uchar *to, uchar *from, uint len)
{
uint i, res= 1;
@@ -32,6 +33,7 @@ static my_bool memcpy_and_test(uchar *to, uchar *from, uint len)
res= 0;
return res;
}
#endif

#if defined(__APPLE__) || defined(__FreeBSD__)
#include <net/ethernet.h>
@@ -195,4 +197,3 @@ int main(int argc __attribute__((unused)),char **argv)
return 0;
}
#endif

0 comments on commit 88fb89a

Please sign in to comment.