summaryrefslogtreecommitdiff
path: root/noncore/todayplugins/stockticker/libstocks
authorllornkcor <llornkcor>2002-10-31 20:32:13 (UTC)
committer llornkcor <llornkcor>2002-10-31 20:32:13 (UTC)
commit73b03f932dd43d684e67db1837bf506ee015f2eb (patch) (unidiff)
tree87be47c236586177c65b38216818951337c0b59a /noncore/todayplugins/stockticker/libstocks
parent50f1091ee877020c9864ce24202951f49bec8cd7 (diff)
downloadopie-73b03f932dd43d684e67db1837bf506ee015f2eb.zip
opie-73b03f932dd43d684e67db1837bf506ee015f2eb.tar.gz
opie-73b03f932dd43d684e67db1837bf506ee015f2eb.tar.bz2
make define __UNIX__ inherent
Diffstat (limited to 'noncore/todayplugins/stockticker/libstocks') (more/less context) (show whitespace changes)
-rw-r--r--noncore/todayplugins/stockticker/libstocks/csv.c1
-rw-r--r--noncore/todayplugins/stockticker/libstocks/http.c1
2 files changed, 2 insertions, 0 deletions
diff --git a/noncore/todayplugins/stockticker/libstocks/csv.c b/noncore/todayplugins/stockticker/libstocks/csv.c
index 99a44e4..27bcce6 100644
--- a/noncore/todayplugins/stockticker/libstocks/csv.c
+++ b/noncore/todayplugins/stockticker/libstocks/csv.c
@@ -1,45 +1,46 @@
1/* libstocks - Library to get current stock quotes from Yahoo Finance 1/* libstocks - Library to get current stock quotes from Yahoo Finance
2 * 2 *
3 * Copyright (C) 2000 Eric Laeuffer 3 * Copyright (C) 2000 Eric Laeuffer
4 * 4 *
5 * This library is free software; you can redistribute it and/or 5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Library General Public 6 * modify it under the terms of the GNU Library General Public
7 * License as published by the Free Software Foundation; either 7 * License as published by the Free Software Foundation; either
8 * version 2 of the License, or (at your option) any later version. 8 * version 2 of the License, or (at your option) any later version.
9 * 9 *
10 * This library is distributed in the hope that it will be useful, 10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Library General Public License for more details. 13 * Library General Public License for more details.
14 * 14 *
15 * You should have received a copy of the GNU Library General Public 15 * You should have received a copy of the GNU Library General Public
16 * License along with this library; if not, write to the 16 * License along with this library; if not, write to the
17 * Free Software Foundation, Inc., 59 Temple Place - Suite 330, 17 * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
18 * Boston, MA 02111-1307, USA. 18 * Boston, MA 02111-1307, USA.
19 */ 19 */
20 20
21#define __CSV_C__ 21#define __CSV_C__
22#ifdef __UNIX__
22 23
23#include <string.h> 24#include <string.h>
24#include <stdlib.h> 25#include <stdlib.h>
25#include <stdio.h> 26#include <stdio.h>
26 27
27#ifdef __WINDOWS__ 28#ifdef __WINDOWS__
28#include <mbstring.h> 29#include <mbstring.h>
29#endif 30#endif
30 31
31#include "csv.h" 32#include "csv.h"
32#include "stocks.h" 33#include "stocks.h"
33#include "lists.h" 34#include "lists.h"
34 35
35#define DATE_LENGTH 7 /*YYMMDD*/ 36#define DATE_LENGTH 7 /*YYMMDD*/
36 37
37const char *months[12]= 38const char *months[12]=
38{ 39{
39 "Jan", 40 "Jan",
40 "Feb", 41 "Feb",
41 "Mar", 42 "Mar",
42 "Apr", 43 "Apr",
43 "May", 44 "May",
44 "Jun", 45 "Jun",
45 "Jul", 46 "Jul",
diff --git a/noncore/todayplugins/stockticker/libstocks/http.c b/noncore/todayplugins/stockticker/libstocks/http.c
index 462080d..3078746 100644
--- a/noncore/todayplugins/stockticker/libstocks/http.c
+++ b/noncore/todayplugins/stockticker/libstocks/http.c
@@ -1,45 +1,46 @@
1/* libstocks - Library to get current stock quotes from Yahoo Finance 1/* libstocks - Library to get current stock quotes from Yahoo Finance
2 * 2 *
3 * Copyright (C) 2000 Eric Laeuffer 3 * Copyright (C) 2000 Eric Laeuffer
4 * 4 *
5 * This library is free software; you can redistribute it and/or 5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Library General Public 6 * modify it under the terms of the GNU Library General Public
7 * License as published by the Free Software Foundation; either 7 * License as published by the Free Software Foundation; either
8 * version 2 of the License, or (at your option) any later version. 8 * version 2 of the License, or (at your option) any later version.
9 * 9 *
10 * This library is distributed in the hope that it will be useful, 10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Library General Public License for more details. 13 * Library General Public License for more details.
14 * 14 *
15 * You should have received a copy of the GNU Library General Public 15 * You should have received a copy of the GNU Library General Public
16 * License along with this library; if not, write to the 16 * License along with this library; if not, write to the
17 * Free Software Foundation, Inc., 59 Temple Place - Suite 330, 17 * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
18 * Boston, MA 02111-1307, USA. 18 * Boston, MA 02111-1307, USA.
19 */ 19 */
20 20
21#define __HTTP_C__ 21#define __HTTP_C__
22#define __UNIX__
22 23
23#ifdef __UNIX__ 24#ifdef __UNIX__
24#include <sys/socket.h> 25#include <sys/socket.h>
25#include <netinet/in.h> 26#include <netinet/in.h>
26#include <arpa/inet.h> 27#include <arpa/inet.h>
27#include <netdb.h> 28#include <netdb.h>
28#include <unistd.h> 29#include <unistd.h>
29#elif __WINDOWS__ 30#elif __WINDOWS__
30#include <winsock.h> 31#include <winsock.h>
31#include <mbstring.h> 32#include <mbstring.h>
32#endif 33#endif
33 34
34#include <sys/types.h> 35#include <sys/types.h>
35#include <ctype.h> 36#include <ctype.h>
36#include <string.h> 37#include <string.h>
37#include <stdlib.h> 38#include <stdlib.h>
38#include <stdio.h> 39#include <stdio.h>
39 40
40#include "http.h" 41#include "http.h"
41#include "stocks.h" 42#include "stocks.h"
42 43
43#define BUF_SIZE 1024 44#define BUF_SIZE 1024
44#define HEADER_MAXBUF 512 45#define HEADER_MAXBUF 512
45 46