You've already forked mariadb-columnstore-engine
mirror of
https://github.com/mariadb-corporation/mariadb-columnstore-engine.git
synced 2025-06-13 16:01:32 +03:00
MCOL-537 Enabled -Wno-unused-result for OAM code.
Fixed pragmas that disables compilation checks. DDLProc now returns an error if it couldn't cwd. Use either auto_ptr or unique_ptr depending on GCC version.
This commit is contained in:
@ -945,7 +945,6 @@ void InetStreamSocket::connect(const sockaddr* serv_addr)
|
||||
/* read a byte to artificially synchronize with accept() on the remote */
|
||||
int ret = -1;
|
||||
int e = EBADF;
|
||||
char buf = '\0';
|
||||
struct pollfd pfd;
|
||||
|
||||
long msecs = fConnectionTimeout.tv_sec * 1000 + fConnectionTimeout.tv_nsec / 1000000;
|
||||
@ -964,11 +963,16 @@ void InetStreamSocket::connect(const sockaddr* serv_addr)
|
||||
if (ret == 1)
|
||||
{
|
||||
#ifdef _MSC_VER
|
||||
char buf = '\0';
|
||||
(void)::recv(socketParms().sd(), &buf, 1, 0);
|
||||
#else
|
||||
#pragma GCC diagnostic ignored "-Wunused-result"
|
||||
::read(socketParms().sd(), &buf, 1); // we know 1 byte is in the recv buffer
|
||||
#pragma GCC diagnostic pop
|
||||
#if defined(__GNUC__) && __GNUC__ >= 5
|
||||
#pragma GCC diagnostic push
|
||||
#pragma GCC diagnostic ignored "-Wunused-result"
|
||||
char buf = '\0';
|
||||
ssize_t bytes = ::read(socketParms().sd(), &buf, 1); // we know 1 byte is in the recv buffer
|
||||
#pragma GCC diagnostic pop
|
||||
#endif // pragma
|
||||
#endif
|
||||
return;
|
||||
}
|
||||
|
Reference in New Issue
Block a user