mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 572659 - Don't expose the Gecko patch level (13.X.Y) in the UA string, only show the major version (13.X). r=glandium,bz sr=gerv
This commit is contained in:
parent
64de674dcd
commit
db675026d9
@ -51,6 +51,7 @@ use vars qw(
|
||||
$MICRO_VERSION
|
||||
$opt_debug
|
||||
$opt_template
|
||||
$opt_uaversion
|
||||
$opt_help
|
||||
);
|
||||
|
||||
@ -60,7 +61,7 @@ push(@INC,$SCRIPTDIR);
|
||||
|
||||
require "Moz/Milestone.pm";
|
||||
|
||||
&GetOptions('topsrcdir=s' => \$TOPSRCDIR, 'srcdir=s' => \$SRCDIR, 'objdir=s' => \$OBJDIR, 'debug', 'help', 'template');
|
||||
&GetOptions('topsrcdir=s' => \$TOPSRCDIR, 'srcdir=s' => \$SRCDIR, 'objdir=s' => \$OBJDIR, 'debug', 'help', 'template', 'uaversion');
|
||||
|
||||
if (defined($opt_help)) {
|
||||
&usage();
|
||||
@ -100,13 +101,19 @@ if (defined(@TEMPLATE_FILE)) {
|
||||
warn("$0: No such file $TFILE!\n");
|
||||
}
|
||||
}
|
||||
} elsif(defined($opt_uaversion)) {
|
||||
my $uaversion = Moz::Milestone::getMilestoneMajor($milestone) . "." .
|
||||
Moz::Milestone::getMilestoneMinor($milestone);
|
||||
# strip off trailing pre-release indicators
|
||||
$uaversion =~ s/[a-z]+\d*$//;
|
||||
print "$uaversion\n";
|
||||
} else {
|
||||
print "$milestone\n";
|
||||
}
|
||||
|
||||
sub usage() {
|
||||
print <<END
|
||||
`milestone.pl [--topsrcdir TOPSRCDIR] [--objdir OBJDIR] [--srcdir SRCDIR] --template [file list]` # will build file list from .tmpl files
|
||||
`milestone.pl [--topsrcdir TOPSRCDIR] [--objdir OBJDIR] [--srcdir SRCDIR] --template [file list] --uaversion` # will build file list from .tmpl files
|
||||
END
|
||||
;
|
||||
}
|
||||
|
@ -2266,6 +2266,7 @@ fi
|
||||
|
||||
dnl Get mozilla version from central milestone file
|
||||
MOZILLA_VERSION=`$PERL $srcdir/config/milestone.pl -topsrcdir $srcdir`
|
||||
MOZILLA_UAVERSION=`$PERL $srcdir/config/milestone.pl -topsrcdir $srcdir -uaversion`
|
||||
|
||||
dnl Get version of various core apps from the version files.
|
||||
FIREFOX_VERSION=`cat $_topsrcdir/browser/config/version.txt`
|
||||
@ -2276,6 +2277,7 @@ fi
|
||||
|
||||
AC_DEFINE_UNQUOTED(MOZILLA_VERSION,"$MOZILLA_VERSION")
|
||||
AC_DEFINE_UNQUOTED(MOZILLA_VERSION_U,$MOZILLA_VERSION)
|
||||
AC_DEFINE_UNQUOTED(MOZILLA_UAVERSION,"$MOZILLA_UAVERSION")
|
||||
|
||||
MOZ_DOING_LTO(lto_is_enabled)
|
||||
|
||||
|
@ -51,6 +51,7 @@ use vars qw(
|
||||
$MICRO_VERSION
|
||||
$opt_debug
|
||||
$opt_template
|
||||
$opt_uaversion
|
||||
$opt_help
|
||||
);
|
||||
|
||||
@ -60,7 +61,7 @@ push(@INC,$SCRIPTDIR);
|
||||
|
||||
require "Moz/Milestone.pm";
|
||||
|
||||
&GetOptions('topsrcdir=s' => \$TOPSRCDIR, 'srcdir=s' => \$SRCDIR, 'objdir=s' => \$OBJDIR, 'debug', 'help', 'template');
|
||||
&GetOptions('topsrcdir=s' => \$TOPSRCDIR, 'srcdir=s' => \$SRCDIR, 'objdir=s' => \$OBJDIR, 'debug', 'help', 'template', 'uaversion');
|
||||
|
||||
if (defined($opt_help)) {
|
||||
&usage();
|
||||
@ -100,13 +101,19 @@ if (defined(@TEMPLATE_FILE)) {
|
||||
warn("$0: No such file $TFILE!\n");
|
||||
}
|
||||
}
|
||||
} elsif(defined($opt_uaversion)) {
|
||||
my $uaversion = Moz::Milestone::getMilestoneMajor($milestone) . "." .
|
||||
Moz::Milestone::getMilestoneMinor($milestone);
|
||||
# strip off trailing pre-release indicators
|
||||
$uaversion =~ s/[a-z]+\d*$//;
|
||||
print "$uaversion\n";
|
||||
} else {
|
||||
print "$milestone\n";
|
||||
}
|
||||
|
||||
sub usage() {
|
||||
print <<END
|
||||
`milestone.pl [--topsrcdir TOPSRCDIR] [--objdir OBJDIR] [--srcdir SRCDIR] --template [file list]` # will build file list from .tmpl files
|
||||
`milestone.pl [--topsrcdir TOPSRCDIR] [--objdir OBJDIR] [--srcdir SRCDIR] --template [file list] --uaversion` # will build file list from .tmpl files
|
||||
END
|
||||
;
|
||||
}
|
||||
|
@ -270,7 +270,7 @@ nsHttpHandler::Init()
|
||||
PrefsChanged(prefBranch, nsnull);
|
||||
}
|
||||
|
||||
mMisc.AssignLiteral("rv:" MOZILLA_VERSION);
|
||||
mMisc.AssignLiteral("rv:" MOZILLA_UAVERSION);
|
||||
|
||||
nsCOMPtr<nsIXULAppInfo> appInfo =
|
||||
do_GetService("@mozilla.org/xre/app-info;1");
|
||||
@ -307,7 +307,7 @@ nsHttpHandler::Init()
|
||||
rv = InitConnectionMgr();
|
||||
if (NS_FAILED(rv)) return rv;
|
||||
|
||||
mProductSub.AssignLiteral(MOZILLA_VERSION);
|
||||
mProductSub.AssignLiteral(MOZILLA_UAVERSION);
|
||||
|
||||
// Startup the http category
|
||||
// Bring alive the objects in the http-protocol-startup category
|
||||
|
Loading…
Reference in New Issue
Block a user