summaryrefslogtreecommitdiffstats
path: root/usr.bin/tip
diff options
context:
space:
mode:
authorimp <imp@FreeBSD.org>2000-04-14 06:39:19 +0000
committerimp <imp@FreeBSD.org>2000-04-14 06:39:19 +0000
commit4721d7ef435f4d79e92d8d98ba9b645bb25993fb (patch)
treec7963b41252b2e47e3e9896854edbbb0300e6576 /usr.bin/tip
parent7fec3d2787608459e561d33aa2c5f4370c7eb11f (diff)
downloadFreeBSD-src-4721d7ef435f4d79e92d8d98ba9b645bb25993fb.zip
FreeBSD-src-4721d7ef435f4d79e92d8d98ba9b645bb25993fb.tar.gz
#include <errno.h> where needed. Kill extern int errno;.
Minor warnings in tip corrected.
Diffstat (limited to 'usr.bin/tip')
-rw-r--r--usr.bin/tip/libacu/dn11.c4
-rw-r--r--usr.bin/tip/libacu/v831.c4
-rw-r--r--usr.bin/tip/tip/cmds.c3
-rw-r--r--usr.bin/tip/tip/tip.c2
-rw-r--r--usr.bin/tip/tip/tip.h4
-rw-r--r--usr.bin/tip/tip/tipout.c2
-rw-r--r--usr.bin/tip/tip/value.c4
7 files changed, 15 insertions, 8 deletions
diff --git a/usr.bin/tip/libacu/dn11.c b/usr.bin/tip/libacu/dn11.c
index 52749da..6a2fc3e 100644
--- a/usr.bin/tip/libacu/dn11.c
+++ b/usr.bin/tip/libacu/dn11.c
@@ -29,6 +29,8 @@
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
+ *
+ * $FreeBSD$
*/
#ifndef lint
@@ -40,6 +42,7 @@ static char sccsid[] = "@(#)dn11.c 8.1 (Berkeley) 6/6/93";
*/
#include "tipconf.h"
#include "tip.h"
+#include <errno.h>
int dn_abort();
void alarmtr();
@@ -49,7 +52,6 @@ static int child = -1, dn;
dn_dialer(num, acu)
char *num, *acu;
{
- extern errno;
char *p, *q, phone[40];
int lt, nw, connected = 1;
register int timelim;
diff --git a/usr.bin/tip/libacu/v831.c b/usr.bin/tip/libacu/v831.c
index b670c2a..e02121c 100644
--- a/usr.bin/tip/libacu/v831.c
+++ b/usr.bin/tip/libacu/v831.c
@@ -29,6 +29,8 @@
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
+ *
+ * $FreeBSD$
*/
#ifndef lint
@@ -40,10 +42,10 @@ static char sccsid[] = "@(#)v831.c 8.1 (Berkeley) 6/6/93";
*/
#include "tipconf.h"
#include "tip.h"
+#include <errno.h>
int v831_abort();
static void alarmtr();
-extern int errno;
static jmp_buf jmpbuf;
static int child = -1;
diff --git a/usr.bin/tip/tip/cmds.c b/usr.bin/tip/tip/cmds.c
index ec57346..10198ba 100644
--- a/usr.bin/tip/tip/cmds.c
+++ b/usr.bin/tip/tip/cmds.c
@@ -725,7 +725,7 @@ tiplink (char *cmd, unsigned int flags)
* 1 <-> remote tty out
* 2 <-> local tty out
*/
-void
+int
consh(c)
{
char buf[256];
@@ -733,6 +733,7 @@ consh(c)
if (prompt("Local command? ", buf, sizeof(buf)))
return;
tiplink (buf, TL_SIGNAL_TIPOUT | TL_VERBOSE);
+ return 0;
}
#endif
diff --git a/usr.bin/tip/tip/tip.c b/usr.bin/tip/tip/tip.c
index 348f8a0..2b11d0b 100644
--- a/usr.bin/tip/tip/tip.c
+++ b/usr.bin/tip/tip/tip.c
@@ -58,6 +58,7 @@ void ttysetup (int speed);
*/
#include <err.h>
+#include <errno.h>
#include <sys/types.h>
#include <libutil.h>
#include "tipconf.h"
@@ -666,7 +667,6 @@ xpwrite(fd, buf, n)
{
register int i;
register char *bp;
- extern int errno;
bp = buf;
if (bits8 == 0)
diff --git a/usr.bin/tip/tip/tip.h b/usr.bin/tip/tip/tip.h
index ea841ff..9aa69c2 100644
--- a/usr.bin/tip/tip/tip.h
+++ b/usr.bin/tip/tip/tip.h
@@ -32,6 +32,8 @@
* SUCH DAMAGE.
*
* @(#)tip.h 8.1 (Berkeley) 6/6/93
+ *
+ * $FreeBSD$
*/
/*
@@ -318,7 +320,7 @@ extern void shell_uid __P((void));
extern void unraw __P((void));
extern void xpwrite __P((int, char *, int));
extern int prompt __P((char *, char *, size_t));
-extern void consh __P((int));
+extern int consh __P((int));
extern void tipabort __P((char *));
#define TL_VERBOSE 0x00000001
diff --git a/usr.bin/tip/tip/tipout.c b/usr.bin/tip/tip/tipout.c
index c9292a8..de1fe6a 100644
--- a/usr.bin/tip/tip/tipout.c
+++ b/usr.bin/tip/tip/tipout.c
@@ -40,6 +40,7 @@ static const char rcsid[] =
#endif /* not lint */
#include "tip.h"
+#include <errno.h>
/*
* tip
*
@@ -122,7 +123,6 @@ tipout()
char buf[BUFSIZ];
register char *cp;
register int cnt;
- extern int errno;
int omask;
signal(SIGINT, SIG_IGN);
diff --git a/usr.bin/tip/tip/value.c b/usr.bin/tip/tip/value.c
index 8be5cd9..0c103c8 100644
--- a/usr.bin/tip/tip/value.c
+++ b/usr.bin/tip/tip/value.c
@@ -185,7 +185,7 @@ vtoken(s)
if ((p = vlookup(s))) {
cp++;
if (p->v_type&NUMBER)
- vassign(p, atoi(cp));
+ vassign(p, (char *) atoi(cp));
else {
if (strcmp(s, "record") == 0)
cp = expand(cp);
@@ -358,7 +358,7 @@ vstring(s,v)
if (p == 0)
return (1);
if (p->v_type&NUMBER)
- vassign(p, atoi(v));
+ vassign(p, (char *) atoi(v));
else {
if (strcmp(s, "record") == 0)
v = expand(v);
OpenPOWER on IntegriCloud