If no ENETUNREACH (Win32), use EINVAL.
authorTor Lillqvist <tml@novell.com>
Thu, 15 Sep 2005 18:08:50 +0000 (18:08 +0000)
committerTor Lillqvist <tml@src.gnome.org>
Thu, 15 Sep 2005 18:08:50 +0000 (18:08 +0000)
2005-09-15  Tor Lillqvist  <tml@novell.com>

* camel-imap-wrapper.c: If no ENETUNREACH (Win32), use EINVAL.

camel/providers/imap/ChangeLog
camel/providers/imap/camel-imap-wrapper.c

index 3031041..72543ad 100644 (file)
@@ -17,6 +17,8 @@
        IMAP servers is not supported on Win32 (at least for now), so
        bypass that code.
 
+       * camel-imap-wrapper.c: If no ENETUNREACH (Win32), use EINVAL.
+
 2005-08-23  Shreyas Srinivasan  <sshreyas@novell.com>
 
        ** See #314199
index 04fd2cf..e08a89f 100644 (file)
@@ -139,7 +139,12 @@ write_to_stream (CamelDataWrapper *data_wrapper, CamelStream *stream)
                        imap_wrapper->part_spec, FALSE, NULL);
                if (!datastream) {
                        CAMEL_IMAP_WRAPPER_UNLOCK (imap_wrapper, lock);
+#ifdef ENETUNREACH
                        errno = ENETUNREACH;
+#else
+#warning FIXME: what errno to use if no ENETUNREACH
+                       errno = EINVAL;
+#endif
                        return -1;
                }