summaryrefslogtreecommitdiff
path: root/mysys/my_gethwaddr.c
diff options
context:
space:
mode:
authorunknown <joerg@trift2.>2007-08-09 14:56:57 +0200
committerunknown <joerg@trift2.>2007-08-09 14:56:57 +0200
commit9a6a339e4ab1284e3124d99a18b7c7688f7f85dc (patch)
treed6fd73ff983c395bee461b7a287866a806efbd82 /mysys/my_gethwaddr.c
parent3f8a904fad73d7e39a16d1f6fb0ccf0d0cfc6b9d (diff)
downloadmariadb-git-9a6a339e4ab1284e3124d99a18b7c7688f7f85dc.tar.gz
mysys/my_gethwaddr.c
Fix a typing error in a conditional compiling directive (reported by Vasil Dimov: Thanks !), and improve their nesting ("MAIN" independent of platform). mysys/my_gethwaddr.c: Fix a typing error, reported by Vasil Dimov (thanks !): The condition is meant to apply to FreeBSD or Linux. Improve the nesting of conditional compiling directives, handle "MAIN" and the platform issues independent of each other.
Diffstat (limited to 'mysys/my_gethwaddr.c')
-rw-r--r--mysys/my_gethwaddr.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/mysys/my_gethwaddr.c b/mysys/my_gethwaddr.c
index 845b5aa4152..c7f138c7337 100644
--- a/mysys/my_gethwaddr.c
+++ b/mysys/my_gethwaddr.c
@@ -19,7 +19,9 @@
#include "mysys_priv.h"
#include <m_string.h>
-#if !defined(__FreeBSD__) || defined(__linux__)
+#ifndef MAIN
+
+#if defined(__FreeBSD__) || defined(__linux__)
static my_bool memcpy_and_test(uchar *to, uchar *from, uint len)
{
uint i, res=1;
@@ -29,6 +31,7 @@ static my_bool memcpy_and_test(uchar *to, uchar *from, uint len)
res=0;
return res;
}
+#endif /* FreeBSD || linux */
#ifdef __FreeBSD__
@@ -98,7 +101,7 @@ err:
return res;
}
-#else
+#else /* FreeBSD elif linux */
/* just fail */
my_bool my_gethwaddr(uchar *to __attribute__((unused)))
{