Description: Use the pager program that was choosen with the Debian
  update-alternative system. (Updated line numbers for 0.99.22)
Author: Christian Hammers <ch@debian.org>

--- old/vtysh/vtysh.c.orig	2004-10-18 01:23:16.000000000 +0200
+++ new/vtysh/vtysh.c	2004-10-18 01:25:15.000000000 +0200
@@ -265,10 +265,16 @@
 
   pager_defined = getenv ("VTYSH_PAGER");
 
-  if (pager_defined)
+  if (pager_defined) {
     vtysh_pager_name = strdup (pager_defined);
-  else
-    vtysh_pager_name = strdup ("more");
+  } else {
+    struct stat pager_stat;
+    if (stat("/usr/bin/pager", &pager_stat) == 0) {
+      vtysh_pager_name = strdup ("/usr/bin/pager");
+    } else {
+      vtysh_pager_name = strdup ("more");
+    }
+  }
 }
 
 /* Command execution over the vty interface. */
