OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "printing/backend/print_backend_cups.h" | 5 #include "printing/backend/print_backend_cups.h" |
6 | 6 |
| 7 #include <cups/ppd.h> |
7 #include <dlfcn.h> | 8 #include <dlfcn.h> |
8 #include <errno.h> | 9 #include <errno.h> |
9 #include <pthread.h> | 10 #include <pthread.h> |
10 | 11 |
11 #include <string> | 12 #include <string> |
12 | 13 |
13 #include "base/debug/leak_annotations.h" | 14 #include "base/debug/leak_annotations.h" |
14 #include "base/files/file_util.h" | 15 #include "base/files/file_util.h" |
15 #include "base/lazy_instance.h" | 16 #include "base/lazy_instance.h" |
16 #include "base/logging.h" | 17 #include "base/logging.h" |
(...skipping 268 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
285 // Use default (local) print server. | 286 // Use default (local) print server. |
286 if (print_server_url_.is_empty()) | 287 if (print_server_url_.is_empty()) |
287 return cupsGetNamedDest(CUPS_HTTP_DEFAULT, printer_name.c_str(), nullptr); | 288 return cupsGetNamedDest(CUPS_HTTP_DEFAULT, printer_name.c_str(), nullptr); |
288 | 289 |
289 HttpConnectionCUPS http(print_server_url_, cups_encryption_); | 290 HttpConnectionCUPS http(print_server_url_, cups_encryption_); |
290 http.SetBlocking(blocking_); | 291 http.SetBlocking(blocking_); |
291 return cupsGetNamedDest(http.http(), printer_name.c_str(), nullptr); | 292 return cupsGetNamedDest(http.http(), printer_name.c_str(), nullptr); |
292 } | 293 } |
293 | 294 |
294 } // namespace printing | 295 } // namespace printing |
OLD | NEW |