summaryrefslogtreecommitdiff
path: root/libmysql
diff options
context:
space:
mode:
authormonty@hundin.mysql.fi <>2002-05-31 15:22:38 +0300
committermonty@hundin.mysql.fi <>2002-05-31 15:22:38 +0300
commite2a116411e7b293b5d0d920c8a94794dd75dd334 (patch)
tree85c51f351e6086eebde739636a64e7ab09b85277 /libmysql
parenta2ec51cec16205154aa2c7f5ecf6ec3c98a978e8 (diff)
downloadmariadb-git-e2a116411e7b293b5d0d920c8a94794dd75dd334.tar.gz
Portability fixes for SCO and HPUX
Change TRUNCATE(number) to truncate towards zero for negative numbers Fix NULL handling for DESCRIBE table_name
Diffstat (limited to 'libmysql')
-rw-r--r--libmysql/libmysql.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/libmysql/libmysql.c b/libmysql/libmysql.c
index 4190a4c37f4..bab6d304094 100644
--- a/libmysql/libmysql.c
+++ b/libmysql/libmysql.c
@@ -180,8 +180,13 @@ static int connect2(my_socket s, const struct sockaddr *name, uint namelen,
{
tv.tv_sec = (long) timeout;
tv.tv_usec = 0;
+#if defined(HPUX) && defined(THREAD)
+ if ((res = select(s+1, NULL, (int*) &sfds, NULL, &tv)) >= 0)
+ break;
+#else
if ((res = select(s+1, NULL, &sfds, NULL, &tv)) >= 0)
break;
+#endif
now_time=time(NULL);
timeout-= (uint) (now_time - start_time);
if (errno != EINTR || (int) timeout <= 0)