bug-mailutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [bug-mailutils] Building on Solaris


From: Sergey Poznyakoff
Subject: Re: [bug-mailutils] Building on Solaris
Date: Mon, 17 Jan 2005 11:20:59 +0200

HJello Alex,

Alex S Moore <address@hidden> wrote:

> I get the following error and do not see how to fix it.  So I need
> help again, please.
[...]
> Undefined                       first referenced 
> symbol                            in file 
> alloca                             ../mailbox/nntp/.libs/libmu_nntp.so 

Please apply the attached patch.

Thank you for reporting the problem.

Regards,
Sergey

Index: mailbox/nntp/folder.c
===================================================================
RCS file: /cvsroot/mailutils/mailutils/mailbox/nntp/folder.c,v
retrieving revision 1.2
diff -p -u -r1.2 folder.c
--- mailbox/nntp/folder.c       7 Aug 2004 09:07:18 -0000       1.2
+++ mailbox/nntp/folder.c       17 Jan 2005 09:16:21 -0000
@@ -113,7 +113,9 @@ nntp_folder_open (folder_t folder, int f
   status = url_get_host (folder->url, NULL, 0, &len);
   if (status != 0)
     return status;
-  host = alloca (len + 1);
+  host = malloc (len + 1);
+  if (!host)
+    return ENOMEM;
   url_get_host (folder->url, host, len + 1, NULL);
   url_get_port (folder->url, &port);
 
@@ -121,6 +123,7 @@ nntp_folder_open (folder_t folder, int f
 
   /* Create the networking stack.  */
   status = tcp_stream_create (&carrier, host, port, folder->flags);
+  free (host);
   if (status != 0)
     return status;
   /* Ask for the stream internal buffering mechanism scheme.  */
Index: mailbox/nntp/mbox.c
===================================================================
RCS file: /cvsroot/mailutils/mailutils/mailbox/nntp/mbox.c,v
retrieving revision 1.2
diff -p -u -r1.2 mbox.c
--- mailbox/nntp/mbox.c 7 Aug 2004 09:07:18 -0000       1.2
+++ mailbox/nntp/mbox.c 17 Jan 2005 09:16:21 -0000
@@ -32,10 +32,6 @@
 #include <fcntl.h>
 #include <stdarg.h>
 
-#ifdef HAVE_ALLOCA_H
-# include <alloca.h>
-#endif
-
 #ifdef HAVE_STRINGS_H
 # include <strings.h>
 #endif

reply via email to

[Prev in Thread] Current Thread [Next in Thread]