cURL / Mailing Lists / curl-users / Single Mail

curl-users

Re: cURL for VAX VMS 6.2

From: Daniel Stenberg <daniel-curl_at_haxx.se>
Date: Sat, 23 Oct 2004 10:53:04 +0200 (CEST)

On Fri, 22 Oct 2004, Robert Bustichi wrote:

> It looks like my sticking point is the strdup function which is not
> available until VMS 7.0. Any suggestions on how to duplicate this function
> to get these last two files to compile?

Wow. If this is true, you are really close to getting it runnning. I suggest
you make a strdup() similar to this:

char *strdup(const char *s)
{
   size_t len = strlen(s)+1; /* get one extra for the zero byte */
   char *clone = malloc(len);

   if(clone)
     memcpy(clone, s, len);

   return clone;
}

(I'll add this and the proper configure/ifdef magic to the main source when
you have everything working, so that the next version of curl will build
out-of-the-box for you.)

-- 
      Daniel Stenberg -- http://curl.haxx.se -- http://daniel.haxx.se
       Dedicated custom curl help for hire: http://haxx.se/curl.html
Received on 2004-10-23