aboutsummaryrefslogtreecommitdiff
path: root/release/picobsd/tinyware
diff options
context:
space:
mode:
authorDoug White <dwhite@FreeBSD.org>1999-08-22 21:45:24 +0000
committerDoug White <dwhite@FreeBSD.org>1999-08-22 21:45:24 +0000
commit843fcabd9e990311f671867d37541fdc069c7e90 (patch)
treed899abcbd5f26e22445df9dfccd04489b7c7a17f /release/picobsd/tinyware
parent2237f6ec54913903503ff99429037da706cdd65a (diff)
downloadsrc-843fcabd9e990311f671867d37541fdc069c7e90.tar.gz
src-843fcabd9e990311f671867d37541fdc069c7e90.zip
Major PicoBSD update by luigi with some debugging help from myself.
. Now builds on -STABLE (-CURRENT is broken due to bugs) . etc directory contents centralized instead of in each type directory (can exclude & override as desired) . Removed extraneous language files (lang files for rc really necessary?) . dialog-based build tool with support for custom floppy builds . MFS image loads as a mfs_root module instead of compiled into kernel THIS IS BROKEN ON CURRENT. I'll MFC to -STABLE immediately following. luigi tells me I have an OK from jkh on the MFC. Submitted by: luigi
Notes
Notes: svn path=/head/; revision=50186
Diffstat (limited to 'release/picobsd/tinyware')
-rw-r--r--release/picobsd/tinyware/ns/ns.c20
-rw-r--r--release/picobsd/tinyware/simple_httpd/Makefile2
-rw-r--r--release/picobsd/tinyware/simple_httpd/README2
-rw-r--r--release/picobsd/tinyware/simple_httpd/simple_httpd.c2
-rw-r--r--release/picobsd/tinyware/vm/vm.c5
5 files changed, 13 insertions, 18 deletions
diff --git a/release/picobsd/tinyware/ns/ns.c b/release/picobsd/tinyware/ns/ns.c
index 7f3db556cbc6..05c561e43479 100644
--- a/release/picobsd/tinyware/ns/ns.c
+++ b/release/picobsd/tinyware/ns/ns.c
@@ -135,15 +135,11 @@ sock_ntop(const struct sockaddr *sa, size_t salen)
}
case AF_LINK: {
struct sockaddr_dl *sdl = (struct sockaddr_dl *) sa;
- int l = sdl->sdl_nlen ;
- if (l >= sizeof(str) )
- l = sizeof(str) - 1 ;
-
- if (l > 0) {
- strncpy(str, &sdl->sdl_data[0], l);
- str[l] = '\0';
- } else
+ if (sdl->sdl_nlen > 0)
+ snprintf(str, sizeof(str), "%*s",
+ sdl->sdl_nlen, &sdl->sdl_data[0]);
+ else
snprintf(str, sizeof(str), "link#%d", sdl->sdl_index);
return(str);
}
@@ -307,15 +303,16 @@ print_routing(char *proto)
printf("----------------\n");
printf("Name Mtu Network Address "
"Ipkts Ierrs Opkts Oerrs Coll\n");
- i=0;
- for(next=if_buf;next<lim;next+=ifm->ifm_msglen) {
+ }
+ i=0;
+ for(next=if_buf;next<lim;next+=ifm->ifm_msglen) {
ifm=(struct if_msghdr *)next;
if_table[i]=(struct sockaddr *)(ifm+1);
ifm_table[i]=ifm;
sa = if_table[i];
- if (sa->sa_family == AF_LINK) {
+ if (iflag && sa->sa_family == AF_LINK) {
struct sockaddr_dl *sdl = (struct sockaddr_dl *) sa;
printf("%-4s %-5d <Link> ",
@@ -336,7 +333,6 @@ print_routing(char *proto)
);
}
i++;
- }
}
if (!rflag) {
free(rt_buf);
diff --git a/release/picobsd/tinyware/simple_httpd/Makefile b/release/picobsd/tinyware/simple_httpd/Makefile
index 626f1c18ca49..34864a5fc7b8 100644
--- a/release/picobsd/tinyware/simple_httpd/Makefile
+++ b/release/picobsd/tinyware/simple_httpd/Makefile
@@ -1,4 +1,4 @@
-# $Id: Makefile,v 1.3 1999/02/12 20:36:13 abial Exp $
+# $Id: Makefile,v 1.2.2.2 1999/05/05 07:31:31 abial Exp $
#
PROG=simple_httpd
SRCS= simple_httpd.c
diff --git a/release/picobsd/tinyware/simple_httpd/README b/release/picobsd/tinyware/simple_httpd/README
index eafeb26d637a..be4d7d97fd6c 100644
--- a/release/picobsd/tinyware/simple_httpd/README
+++ b/release/picobsd/tinyware/simple_httpd/README
@@ -164,4 +164,4 @@ This program was originally contributed by Marc Nicholas <marc@netstor.com>
Major rewrite by William Lloyd <wlloyd@slap.net>
-$Id:$
+$Id: README,v 1.2.2.2 1999/05/05 07:31:32 abial Exp $
diff --git a/release/picobsd/tinyware/simple_httpd/simple_httpd.c b/release/picobsd/tinyware/simple_httpd/simple_httpd.c
index ddb593baebfd..388623548a4a 100644
--- a/release/picobsd/tinyware/simple_httpd/simple_httpd.c
+++ b/release/picobsd/tinyware/simple_httpd/simple_httpd.c
@@ -27,7 +27,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id:$
+ * $Id: simple_httpd.c,v 1.2.2.2 1999/05/05 07:31:33 abial Exp $
*/
#include <sys/stat.h>
diff --git a/release/picobsd/tinyware/vm/vm.c b/release/picobsd/tinyware/vm/vm.c
index 4babb246aafb..8e089d8916cf 100644
--- a/release/picobsd/tinyware/vm/vm.c
+++ b/release/picobsd/tinyware/vm/vm.c
@@ -26,14 +26,13 @@
* $Id: vm.c,v 1.2 1998/10/29 12:38:06 abial Exp $
*/
+#include <stdio.h>
#include <sys/types.h>
-#include <sys/param.h>
#include <sys/sysctl.h>
#include <sys/vmmeter.h>
-
#include <vm/vm_param.h>
-#include <stdio.h>
+#define pgtok(a) ((a) * (u_int) DEFAULT_PAGE_SIZE >> 10)
int
main(int argc, char *argv[])