media.c (154925) | media.c (156123) |
---|---|
1/* 2 * The new sysinstall program. 3 * 4 * This is probably the last attempt in the `sysinstall' line, the next 5 * generation being slated to essentially a complete rewrite. 6 * | 1/* 2 * The new sysinstall program. 3 * 4 * This is probably the last attempt in the `sysinstall' line, the next 5 * generation being slated to essentially a complete rewrite. 6 * |
7 * $FreeBSD: head/usr.sbin/sysinstall/media.c 154925 2006-01-27 21:00:31Z jkim $ | 7 * $FreeBSD: head/usr.sbin/sysinstall/media.c 156123 2006-02-28 21:49:33Z jhb $ |
8 * 9 * Copyright (c) 1995 10 * Jordan Hubbard. All rights reserved. 11 * 12 * Redistribution and use in source and binary forms, with or without 13 * modification, are permitted provided that the following conditions 14 * are met: 15 * 1. Redistributions of source code must retain the above copyright --- 304 unchanged lines hidden (view full) --- 320 * be an ftp server 321 */ 322int 323mediaSetFTP(dialogMenuItem *self) 324{ 325 static Device ftpDevice; 326 char *cp, hbuf[MAXHOSTNAMELEN], *hostname, *dir; 327 struct addrinfo hints, *res; | 8 * 9 * Copyright (c) 1995 10 * Jordan Hubbard. All rights reserved. 11 * 12 * Redistribution and use in source and binary forms, with or without 13 * modification, are permitted provided that the following conditions 14 * are met: 15 * 1. Redistributions of source code must retain the above copyright --- 304 unchanged lines hidden (view full) --- 320 * be an ftp server 321 */ 322int 323mediaSetFTP(dialogMenuItem *self) 324{ 325 static Device ftpDevice; 326 char *cp, hbuf[MAXHOSTNAMELEN], *hostname, *dir; 327 struct addrinfo hints, *res; |
328 int af, urllen; | 328 int af; 329 size_t urllen; |
329 extern int FtpPort; 330 static Device *networkDev = NULL; 331 332 mediaClose(); 333 cp = variable_get(VAR_FTP_PATH); 334 /* If we've been through here before ... */ 335 if (networkDev && cp && msgYesNo("Re-use old FTP site selection values?")) 336 cp = NULL; --- 212 unchanged lines hidden (view full) --- 549 550int 551mediaSetNFS(dialogMenuItem *self) 552{ 553 static Device nfsDevice; 554 static Device *networkDev = NULL; 555 char *cp, *idx; 556 char hostname[MAXPATHLEN]; | 330 extern int FtpPort; 331 static Device *networkDev = NULL; 332 333 mediaClose(); 334 cp = variable_get(VAR_FTP_PATH); 335 /* If we've been through here before ... */ 336 if (networkDev && cp && msgYesNo("Re-use old FTP site selection values?")) 337 cp = NULL; --- 212 unchanged lines hidden (view full) --- 550 551int 552mediaSetNFS(dialogMenuItem *self) 553{ 554 static Device nfsDevice; 555 static Device *networkDev = NULL; 556 char *cp, *idx; 557 char hostname[MAXPATHLEN]; |
557 int pathlen; | 558 size_t pathlen; |
558 559 mediaClose(); 560 cp = variable_get_value(VAR_NFS_PATH, "Please enter the full NFS file specification for the remote\n" 561 "host and directory containing the FreeBSD distribution files.\n" 562 "This should be in the format: hostname:/some/freebsd/dir", 0); 563 if (!cp) 564 return DITEM_FAILURE; 565 SAFE_STRCPY(hostname, cp); --- 325 unchanged lines hidden --- | 559 560 mediaClose(); 561 cp = variable_get_value(VAR_NFS_PATH, "Please enter the full NFS file specification for the remote\n" 562 "host and directory containing the FreeBSD distribution files.\n" 563 "This should be in the format: hostname:/some/freebsd/dir", 0); 564 if (!cp) 565 return DITEM_FAILURE; 566 SAFE_STRCPY(hostname, cp); --- 325 unchanged lines hidden --- |