- Timestamp:
- Apr 25, 2005, 6:05:57 PM (20 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/ntripclient/NtripLinuxClient.c
r17 r19 1 1 /* 2 2 Easy example NTRIP client for Linux/Unix. 3 $Id: NtripLinuxClient.c,v 1.1 0 2005/02/16 15:23:36stoecker Exp $3 $Id: NtripLinuxClient.c,v 1.11 2005/04/19 11:28:10 stoecker Exp $ 4 4 Copyright (C) 2003-2005 by Dirk Stoecker <soft@dstoecker.de> 5 5 … … 35 35 36 36 #define MAXDATASIZE 1000 /* max number of bytes we can get at once */ 37 char buf[MAXDATASIZE];38 37 39 38 /* CVS revision and version */ 40 static char revisionstr[] = "$Revision: 1.1 0$";41 static char datestr[] = "$Date: 2005/0 2/16 15:23:36$";39 static char revisionstr[] = "$Revision: 1.11 $"; 40 static char datestr[] = "$Date: 2005/04/19 11:28:10 $"; 42 41 43 42 struct Args 44 43 { 45 c har *server;46 int port;47 c har *user;48 c har *password;49 c har *data;44 const char *server; 45 int port; 46 const char *user; 47 const char *password; 48 const char *data; 50 49 }; 51 50 … … 131 130 } 132 131 133 static c har encodingTable [64] = {132 static const char encodingTable [64] = { 134 133 'A','B','C','D','E','F','G','H','I','J','K','L','M','N','O','P', 135 134 'Q','R','S','T','U','V','W','X','Y','Z','a','b','c','d','e','f', … … 140 139 /* does not buffer overrun, but breaks directly after an error */ 141 140 /* returns the number of required bytes */ 142 static int encode(char *buf, int size, c har *user,char *pwd)141 static int encode(char *buf, int size, const char *user, const char *pwd) 143 142 { 144 143 unsigned char inbuf[3]; … … 217 216 "GET / HTTP/1.0\r\n" 218 217 "User-Agent: %s/%s\r\n" 219 // "Accept: */*\r\n" 220 // "Connection: close\r\n" 218 #ifdef UNUSED 219 "Accept: */*\r\n" 220 "Connection: close\r\n" 221 #endif 221 222 "\r\n" 222 223 , AGENTSTRING, revisionstr); … … 227 228 "GET /%s HTTP/1.0\r\n" 228 229 "User-Agent: %s/%s\r\n" 229 // "Accept: */*\r\n" 230 // "Connection: close\r\n" 230 #ifdef UNUSED 231 "Accept: */*\r\n" 232 "Connection: close\r\n" 233 #endif 231 234 "Authorization: Basic " 232 235 , args.data, AGENTSTRING, revisionstr);
Note:
See TracChangeset
for help on using the changeset viewer.