OpenPKG CVS Repository
  http://cvs.openpkg.org/
  ____________________________________________________________________________

  Server: cvs.openpkg.org                  Name:   Thomas Lotterer
  Root:   /e/openpkg/cvs                   Email:  [EMAIL PROTECTED]
  Module: openpkg-src openpkg-web          Date:   23-Oct-2003 15:09:31
  Branch: OPENPKG_1_3_SOLID HEAD           Handle: 2003102314092802

  Modified files:
    openpkg-web             news.txt
  Modified files:           (Branch: OPENPKG_1_3_SOLID)
    openpkg-src/coreutils   coreutils.patch coreutils.spec

  Log:
    workaround to defeat "ls -w" resource starvation

  Summary:
    Revision    Changes     Path
    1.1.2.1.2.2 +62 -0      openpkg-src/coreutils/coreutils.patch
    1.9.2.3.2.3 +1  -1      openpkg-src/coreutils/coreutils.spec
    1.7127      +1  -0      openpkg-web/news.txt
  ____________________________________________________________________________

  patch -p0 <<'@@ .'
  Index: openpkg-src/coreutils/coreutils.patch
  ============================================================================
  $ cvs diff -u -r1.1.2.1.2.1 -r1.1.2.1.2.2 coreutils.patch
  --- openpkg-src/coreutils/coreutils.patch     21 Oct 2003 08:14:29 -0000      
1.1.2.1.2.1
  +++ openpkg-src/coreutils/coreutils.patch     23 Oct 2003 13:09:30 -0000      
1.1.2.1.2.2
  @@ -78,3 +78,65 @@
    /* Define to 1 if you have the `strcspn' function. */
    #undef HAVE_STRCSPN
    
  +http://www.guninski.com/binls.html
  +Workaround to defeat resource starvation using "ls -W hugenumber"
  +taken from Conectiva Updates <[EMAIL PROTECTED]>, CLA-2003:768
  +
  +Index: src/ls.c
  +--- src/ls.c.orig    2003-07-27 08:33:36.000000000 +0200
  ++++ src/ls.c 2003-10-23 13:45:46.000000000 +0200
  +@@ -180,6 +180,8 @@
  + #define ID_LENGTH_MAX \
  +   MAX (LOGIN_NAME_MAX - 1, LONGEST_HUMAN_READABLE)
  + 
  ++#define COLUMNS_MAX 1024
  ++
  + enum filetype
  +   {
  +     unknown DT_INIT (DT_UNKNOWN),
  +@@ -1316,7 +1318,7 @@
  +       {
  +     long int tmp_long;
  +     if (xstrtol (p, NULL, 0, &tmp_long, NULL) == LONGINT_OK
  +-        && 0 < tmp_long && tmp_long <= INT_MAX)
  ++        && 0 < tmp_long && tmp_long <= COLUMNS_MAX)
  +       {
  +         line_length = (int) tmp_long;
  +       }
  +@@ -1334,7 +1336,7 @@
  +     struct winsize ws;
  + 
  +     if (ioctl (STDOUT_FILENO, TIOCGWINSZ, &ws) != -1 && ws.ws_col != 0)
  +-      line_length = ws.ws_col;
  ++      line_length = line_length = MIN(ws.ws_col, COLUMNS_MAX);
  +   }
  + #endif
  + 
  +@@ -1347,7 +1349,7 @@
  +       {
  +     long int tmp_long;
  +     if (xstrtol (p, NULL, 0, &tmp_long, NULL) == LONGINT_OK
  +-        && 0 <= tmp_long && tmp_long <= INT_MAX)
  ++        && 0 <= tmp_long && tmp_long <= COLUMNS_MAX)
  +       {
  +         tabsize = (int) tmp_long;
  +       }
  +@@ -1470,7 +1472,7 @@
  +       {
  +         long int tmp_long;
  +         if (xstrtol (optarg, NULL, 0, &tmp_long, NULL) != LONGINT_OK
  +-            || tmp_long <= 0 || tmp_long > INT_MAX)
  ++            || tmp_long <= 0 || tmp_long > COLUMNS_MAX)
  +           error (EXIT_FAILURE, 0, _("invalid line width: %s"),
  +                  quotearg (optarg));
  +         line_length = (int) tmp_long;
  +@@ -1544,7 +1546,7 @@
  +       {
  +         long int tmp_long;
  +         if (xstrtol (optarg, NULL, 0, &tmp_long, NULL) != LONGINT_OK
  +-            || tmp_long < 0 || tmp_long > INT_MAX)
  ++            || tmp_long < 0 || tmp_long > COLUMNS_MAX)
  +           error (EXIT_FAILURE, 0, _("invalid tab size: %s"),
  +                  quotearg (optarg));
  +         tabsize = (int) tmp_long;
  +
  @@ .
  patch -p0 <<'@@ .'
  Index: openpkg-src/coreutils/coreutils.spec
  ============================================================================
  $ cvs diff -u -r1.9.2.3.2.2 -r1.9.2.3.2.3 coreutils.spec
  --- openpkg-src/coreutils/coreutils.spec      21 Oct 2003 08:14:29 -0000      
1.9.2.3.2.2
  +++ openpkg-src/coreutils/coreutils.spec      23 Oct 2003 13:09:30 -0000      
1.9.2.3.2.3
  @@ -33,7 +33,7 @@
   Group:        Utility
   License:      GPL
   Version:      5.0.1
  -Release:      1.3.1
  +Release:      1.3.2
   
   #   package options
   %option       with_legacy  no
  @@ .
  patch -p0 <<'@@ .'
  Index: openpkg-web/news.txt
  ============================================================================
  $ cvs diff -u -r1.7126 -r1.7127 news.txt
  --- openpkg-web/news.txt      23 Oct 2003 12:50:23 -0000      1.7126
  +++ openpkg-web/news.txt      23 Oct 2003 13:09:28 -0000      1.7127
  @@ -1,3 +1,4 @@
  +23-Oct-2003: Upgraded package: P<coreutils-5.0.1-1.3.2>
   23-Oct-2003: Upgraded package: P<coreutils-5.0.91-20031023>
   23-Oct-2003: Upgraded package: P<sendmail-8.12.10-20031023>
   23-Oct-2003: Upgraded package: P<subversion-0.32.0-20031023>
  @@ .
______________________________________________________________________
The OpenPKG Project                                    www.openpkg.org
CVS Repository Commit List                     [EMAIL PROTECTED]

Reply via email to