diff options
author | Dexter Morgan <dmorgan@mageia.org> | 2011-06-02 20:51:35 +0000 |
---|---|---|
committer | Dexter Morgan <dmorgan@mageia.org> | 2011-06-02 20:51:35 +0000 |
commit | a9b2bdafaf625d10aef2f476aa4014fd36c846bc (patch) | |
tree | 2364afc0ee6739b59a25c44d68c9f003bcaf03d9 /mdk-stage1/url.h | |
download | drakx-a9b2bdafaf625d10aef2f476aa4014fd36c846bc.tar drakx-a9b2bdafaf625d10aef2f476aa4014fd36c846bc.tar.gz drakx-a9b2bdafaf625d10aef2f476aa4014fd36c846bc.tar.bz2 drakx-a9b2bdafaf625d10aef2f476aa4014fd36c846bc.tar.xz drakx-a9b2bdafaf625d10aef2f476aa4014fd36c846bc.zip |
Branch for updates
Diffstat (limited to 'mdk-stage1/url.h')
-rw-r--r-- | mdk-stage1/url.h | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/mdk-stage1/url.h b/mdk-stage1/url.h new file mode 100644 index 000000000..3f5071ebb --- /dev/null +++ b/mdk-stage1/url.h @@ -0,0 +1,46 @@ +/* + * Guillaume Cottenceau (gc@mandriva.com) + * + * Copyright 2000 Mandriva + * + * This software may be freely redistributed under the terms of the GNU + * public license. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * + */ + +/* + * Portions from Erik Troan <ewt@redhat.com> and Matt Wilson <msw@redhat.com> + * + * Copyright 1999 Red Hat, Inc. + * + */ + +#ifndef _URL_H_ +#define _URL_H_ + +int ftp_open_connection(char * host, char * name, char * password, char * proxy); +int ftp_get_filesize(int sock, char * remotename); +int ftp_start_download(int sock, char * remotename, int * size); +int ftp_end_data_command(int sock); +char *str_ftp_error(int error); + +int http_download_file(char * hostname, char * remotename, int * size, char * proxyprotocol, char * proxyname, char * proxyport); + + +#define FTPERR_BAD_SERVER_RESPONSE -1 +#define FTPERR_SERVER_IO_ERROR -2 +#define FTPERR_SERVER_TIMEOUT -3 +#define FTPERR_BAD_HOST_ADDR -4 +#define FTPERR_BAD_HOSTNAME -5 +#define FTPERR_FAILED_CONNECT -6 +#define FTPERR_FILE_IO_ERROR -7 +#define FTPERR_PASSIVE_ERROR -8 +#define FTPERR_FAILED_DATA_CONNECT -9 +#define FTPERR_FILE_NOT_FOUND -10 +#define FTPERR_UNKNOWN -100 + +#endif |