~ubuntu-branches/debian/jessie/ppp/jessie

« back to all changes in this revision

Viewing changes to debian/patches/013_scripts_ip-up.diff

  • Committer: Bazaar Package Importer
  • Author(s): Michael Beattie
  • Date: 2001-12-11 00:24:05 UTC
  • Revision ID: james.westby@ubuntu.com-20011211002405-gcsjlgalwyjf99m2
Tags: 2.4.1.uus-4
Use MAKEDEV in postinst, not mknod. (Closes: #122574)

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
--- ppp-2.4.0b4.orig/scripts/ip-up
 
2
+++ ppp-2.4.0b4/scripts/ip-up
 
3
@@ -0,0 +1,45 @@
 
4
+#!/bin/sh
 
5
+#
 
6
+# $Id: ip-up,v 1.1 1997/12/16 11:37:26 phil Exp $
 
7
+#
 
8
+# This script is run by the pppd after the link is established.
 
9
+# It should be used to add routes, set IP address, run the mailq
 
10
+# etc.
 
11
+#
 
12
+# This script is called with the following arguments:
 
13
+#    Arg  Name               Example
 
14
+#    $1   Interface name     ppp0
 
15
+#    $2   The tty            ttyS1
 
16
+#    $3   The link speed     38400
 
17
+#    $4   Local IP number    12.34.56.78
 
18
+#    $5   Peer  IP number    12.34.56.99
 
19
+
 
20
+# The  environment is cleared before executing this script
 
21
+# so the path must be reset
 
22
+PATH=/usr/local/sbin:/usr/sbin:/sbin:/usr/local/bin:/usr/bin:/bin
 
23
+export PATH
 
24
+# These variables are for the use of the scripts run by run-parts
 
25
+PPP_IFACE="$1"
 
26
+PPP_TTY="$2"
 
27
+PPP_SPEED="$3"
 
28
+PPP_LOCAL="$4"
 
29
+PPP_REMOTE="$5"
 
30
+export PPP_IFACE PPP_TTY PPP_SPEED PPP_LOCAL PPP_REMOTE
 
31
+
 
32
+# as an additional convienince, $PPP_TTYNAME is set to the tty name,
 
33
+# stripped of /dev/ (if present) for easier matching.
 
34
+PPP_TTYNAME=`/usr/bin/basename "$2"`
 
35
+export PPP_TTYNAME
 
36
+
 
37
+# Main Script starts here
 
38
+
 
39
+run-parts /etc/ppp/ip-up.d
 
40
+
 
41
+# if pon was called with the "quick" arg, stop ppp now
 
42
+if [ -r /var/run/ppp-quick ]
 
43
+then
 
44
+    wait
 
45
+    /usr/bin/poff
 
46
+fi
 
47
+
 
48
+# last line