[packages] quagga, quagga-old: use "cat" as default pager and "head -n" as pager...
authorjow <jow@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Tue, 26 Jul 2011 21:46:59 +0000 (21:46 +0000)
committerjow <jow@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Tue, 26 Jul 2011 21:46:59 +0000 (21:46 +0000)
git-svn-id: svn+ssh://svn.openwrt.org/openwrt@27790 3c298f89-4303-0410-b956-a3cf2f4a3e73

Makefile
patches-old/170-use-supported-pagers.patch [new file with mode: 0644]
patches/170-use-supported-pagers.patch [new file with mode: 0644]

index 3dcf0c3524f08903ceffc02727e46fcbc59dfe80..52b74fc1a07acb3e28dc223bd920e33083d5fa07 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -10,12 +10,12 @@ include $(TOPDIR)/rules.mk
 PKG_NAME:=quagga
 ifneq ($(CONFIG_QUAGGA_OLD),)
   PKG_VERSION:=0.98.6
-  PKG_RELEASE:=9
+  PKG_RELEASE:=10
   PKG_MD5SUM:=b0d4132039953a0214256873b7d23d68
   PATCH_DIR:=./patches-old
 else
   PKG_VERSION:=0.99.18
-  PKG_RELEASE:=1
+  PKG_RELEASE:=2
   PKG_MD5SUM:=59e306e93a4a1ce16760f20e9075d473
 endif
 
diff --git a/patches-old/170-use-supported-pagers.patch b/patches-old/170-use-supported-pagers.patch
new file mode 100644 (file)
index 0000000..fca7fc4
--- /dev/null
@@ -0,0 +1,29 @@
+--- a/vtysh/vtysh.c
++++ b/vtysh/vtysh.c
+@@ -243,7 +243,7 @@ vtysh_pager_init ()
+   if (pager_defined)
+     vtysh_pager_name = strdup (pager_defined);
+   else
+-    vtysh_pager_name = strdup ("more");
++    vtysh_pager_name = strdup ("cat");
+ }
+ /* Command execution over the vty interface. */
+@@ -1745,7 +1745,7 @@ DEFUN (vtysh_terminal_length,
+ {
+   int lines;
+   char *endptr = NULL;
+-  char default_pager[10];
++  char default_pager[12];
+   lines = strtol (argv[0], &endptr, 10);
+   if (lines < 0 || lines > 512 || *endptr != '\0')
+@@ -1762,7 +1762,7 @@ DEFUN (vtysh_terminal_length,
+   if (lines != 0)
+     {
+-      snprintf(default_pager, 10, "more -%i", lines);
++      snprintf(default_pager, 12, "head -n %i", lines);
+       vtysh_pager_name = strdup (default_pager);
+     }
diff --git a/patches/170-use-supported-pagers.patch b/patches/170-use-supported-pagers.patch
new file mode 100644 (file)
index 0000000..fe1a4d9
--- /dev/null
@@ -0,0 +1,29 @@
+--- a/vtysh/vtysh.c
++++ b/vtysh/vtysh.c
+@@ -268,7 +268,7 @@ vtysh_pager_init (void)
+   if (pager_defined)
+     vtysh_pager_name = strdup (pager_defined);
+   else
+-    vtysh_pager_name = strdup ("more");
++    vtysh_pager_name = strdup ("cat");
+ }
+ /* Command execution over the vty interface. */
+@@ -1866,7 +1866,7 @@ DEFUN (vtysh_terminal_length,
+ {
+   int lines;
+   char *endptr = NULL;
+-  char default_pager[10];
++  char default_pager[12];
+   lines = strtol (argv[0], &endptr, 10);
+   if (lines < 0 || lines > 512 || *endptr != '\0')
+@@ -1883,7 +1883,7 @@ DEFUN (vtysh_terminal_length,
+   if (lines != 0)
+     {
+-      snprintf(default_pager, 10, "more -%i", lines);
++      snprintf(default_pager, 12, "head -n %i", lines);
+       vtysh_pager_name = strdup (default_pager);
+     }