summaryrefslogtreecommitdiff
path: root/vcl/unx/generic/print
diff options
context:
space:
mode:
authorJulien Nabet <serval2412@yahoo.fr>2018-02-01 16:42:19 +0100
committerJulien Nabet <serval2412@yahoo.fr>2018-02-02 12:07:12 +0100
commitd27ef675ec23f45562972da66bde02d99d778141 (patch)
treee6623a0e739b104f2f96ce30dd7e5f2b84c79945 /vcl/unx/generic/print
parent1287081fa5c132057e01c60a26c6f64156e5bc73 (diff)
Replace some front/pop_front by for-range loops+clear
Change-Id: I8a9239667b0d80ee2fa6ebbc8a19ba4c0076c2fb Reviewed-on: https://gerrit.libreoffice.org/49107 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
Diffstat (limited to 'vcl/unx/generic/print')
-rw-r--r--vcl/unx/generic/print/printerjob.cxx5
1 files changed, 2 insertions, 3 deletions
diff --git a/vcl/unx/generic/print/printerjob.cxx b/vcl/unx/generic/print/printerjob.cxx
index aa6a6f088d64..884bad2eace5 100644
--- a/vcl/unx/generic/print/printerjob.cxx
+++ b/vcl/unx/generic/print/printerjob.cxx
@@ -825,12 +825,11 @@ void PrinterJob::writeJobPatch( osl::File* pFile, const JobData& rJobData )
std::sort(patch_order.begin(), patch_order.end());
patch_order.erase(std::unique(patch_order.begin(), patch_order.end()), patch_order.end());
- while( !patch_order.empty() )
+ for (auto const& elem : patch_order)
{
// note: this discards patch files not adhering to the "int" scheme
// as there won't be a value for them
- writeFeature( pFile, pKey, pKey->getValue( OUString::number( patch_order.front() ) ), false );
- patch_order.pop_front();
+ writeFeature( pFile, pKey, pKey->getValue( OUString::number(elem) ), false );
}
}