zookeeper-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ian Dimayuga (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (ZOOKEEPER-2096) C client builds with incorrect error codes in VisualStudio 2010+
Date Mon, 04 May 2015 18:28:06 GMT

    [ https://issues.apache.org/jira/browse/ZOOKEEPER-2096?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14526998#comment-14526998
] 

Ian Dimayuga commented on ZOOKEEPER-2096:
-----------------------------------------

Hi [~vvs],

Please add the guards as recommended above:
{code}
#ifndef EWOULDBLOCK
#define EWOULDBLOCK WSAEWOULDBLOCK
#endif
 
#ifndef EINPROGRESS
#define EINPROGRESS WSAEINPROGRESS
#endif
{code}


> C client builds with incorrect error codes in VisualStudio 2010+
> ----------------------------------------------------------------
>
>                 Key: ZOOKEEPER-2096
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-2096
>             Project: ZooKeeper
>          Issue Type: Bug
>          Components: build, c client
>         Environment: Windows MSVS 2010+
>            Reporter: Vitaly Stakhovsky
>         Attachments: ZOOKEEPER-2096.patch, ZOOKEEPER-2096.patch, ZOOKEEPER-2096.patch
>
>   Original Estimate: 1h
>  Remaining Estimate: 1h
>
> It reports:
> warning C4005: 'EWOULDBLOCK' : macro redefinition
> warning C4005: 'EINPROGRESS' : macro redefinition
> In MSVS 2010+, these constants are now in <errno.h>.
> What's worse, they have different numeric values.
> Possible fix:
> In "src/c/include/winconfig.h" :
> #if _MSC_VER < 1600
> #define EWOULDBLOCK WSAEWOULDBLOCK
> #define EINPROGRESS WSAEINPROGRESS
> #endif



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message