appdb/include util.php
WineHQ
wineowner at wine.codeweavers.com
Sun Jun 10 19:25:50 CDT 2007
ChangeSet ID: 31180
CVSROOT: /opt/cvs-commit
Module name: appdb
Changes by: wineowner at winehq.org 2007/06/10 19:25:50
Modified files:
include : util.php
Log message:
Chris Morgan <cmorgan at alum.wpi.edu>
Remove "CVS" version from the array of Wine versions we present to the user. It was a dumb idea
to have a CVS version anyway since all CVS versions appear the same.
Patch: http://cvs.winehq.org/patch.py?id=31180
Old revision New revision Changes Path
1.91 1.92 +9 -10 appdb/include/util.php
Index: appdb/include/util.php
diff -u -p appdb/include/util.php:1.91 appdb/include/util.php:1.92
--- appdb/include/util.php:1.91 11 Jun 2007 0:25:50 -0000
+++ appdb/include/util.php 11 Jun 2007 0:25:50 -0000
@@ -168,29 +168,28 @@ function make_bugzilla_version_list($var
// and we can't use 'order by' since we have no column
// to order by, but the entries should come out in the
// order they were added
- // - Trim the list, we don't want every version of wine ever released
- // - Add 'CVS' explicitly since we trim it out
+ // - Trim the list, we don't want every version of wine ever released and
+ // we don't want the "CVS" version included since we can never figure out
+ // what version of Wine any given "CVS" version is
//
// TODO: if we ever get a reasonable way to order the list replace this code
// with that
$aVersions = array();
- while(list($value) = mysql_fetch_row($hResult))
+ while(list($sValue) = mysql_fetch_row($hResult))
{
- // exclude unspecified versions
- if($value != "unspecified")
- $aVersions[] = $value;
+ // exclude unspecified versions and the "CVS" version
+ if(($sValue != "unspecified") && ($sValue != "CVS"))
+ $aVersions[] = $sValue;
}
- // now reverse the array order
+ // now reverse the array order since the oldest
+ // versions were added first
$aVersions = array_reverse($aVersions);
// now trim off all but the last X versions
$iVersionsToKeep = 6;
$aVersions = array_slice($aVersions, 0, $iVersionsToKeep);
- // explicitly add 'CVS' since we are eliminating that above
- $aVersions[] = "CVS";
-
// DONE TRIMMING VERSIONS
/////////////////////////
More information about the wine-cvs
mailing list