]> icculus.org git repositories - icculus/iodoom3.git/blob - neo/curl/docs/examples/simple.c
Various Mac OS X tweaks to get this to build. Probably breaking things.
[icculus/iodoom3.git] / neo / curl / docs / examples / simple.c
1 /*****************************************************************************
2  *                                  _   _ ____  _     
3  *  Project                     ___| | | |  _ \| |    
4  *                             / __| | | | |_) | |    
5  *                            | (__| |_| |  _ <| |___ 
6  *                             \___|\___/|_| \_\_____|
7  *
8  * $Id: simple.c,v 1.5 2002/01/09 13:23:01 bagder Exp $
9  */
10
11 #include <stdio.h>
12 #include <curl/curl.h>
13
14 int main(void)
15 {
16   CURL *curl;
17   CURLcode res;
18
19   curl = curl_easy_init();
20   if(curl) {
21     curl_easy_setopt(curl, CURLOPT_URL, "curl.haxx.se");
22     res = curl_easy_perform(curl);
23
24     /* always cleanup */
25     curl_easy_cleanup(curl);
26   }
27   return 0;
28 }