Bug 1369386 Part 2: Follow-up #if to fix non-Windows build failures. r=me
authorBob Owen <bobowencode@gmail.com>
Fri, 02 Jun 2017 12:07:31 +0100
changeset 362018 a37ca72024c661afc148740be2c3a21e0e20f30e
parent 362017 a8ed8eb7016547be34fa40bb018a02a95042b177
child 362019 4df99c3d89d7eccefd0f348ac5dd9db530c64ac8
push id31955
push userryanvm@gmail.com
push dateFri, 02 Jun 2017 15:10:12 +0000
treeherdermozilla-central@95d2d23ff510 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersme
bugs1369386
milestone55.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1369386 Part 2: Follow-up #if to fix non-Windows build failures. r=me
widget/nsPrintOptionsImpl.cpp
--- a/widget/nsPrintOptionsImpl.cpp
+++ b/widget/nsPrintOptionsImpl.cpp
@@ -492,17 +492,19 @@ nsPrintOptions::ReadPrefs(nsIPrintSettin
     bool success = GETINTPREF(kPrintPaperSizeUnit, &sizeUnit)
                   && GETDBLPREF(kPrintPaperWidth, width)
                   && GETDBLPREF(kPrintPaperHeight, height)
                   && GETSTRPREF(kPrintPaperName, &str);
 
     // Bug 315687: Sanity check paper size to avoid paper size values in
     // mm when the size unit flag is inches. The value 100 is arbitrary
     // and can be changed.
+#if defined(XP_WIN)
     bool saveSanitizedSizePrefs = false;
+#endif
     if (success) {
       success = (sizeUnit != nsIPrintSettings::kPaperSizeInches)
              || (width < 100.0)
              || (height < 100.0);
 #if defined(XP_WIN)
       // Work around legacy invalid prefs where the size unit gets set to
       // millimeters, but the height and width remains as the previous inches
       // settings. See bug 1276717 and bug 1369386 for details.