| 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 "ppapi/proxy/ppp_content_decryptor_private_proxy.h" | 5 #include "ppapi/proxy/ppp_content_decryptor_private_proxy.h" |
| 6 | 6 |
| 7 #include "base/files/file.h" | 7 #include "base/files/file.h" |
| 8 #include "media/base/limits.h" | 8 #include "media/base/limits.h" |
| 9 #include "ppapi/c/pp_bool.h" | 9 #include "ppapi/c/pp_bool.h" |
| 10 #include "ppapi/c/ppb_core.h" | 10 #include "ppapi/c/ppb_core.h" |
| (...skipping 526 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 537 server_certificate.size() > media::limits::kMaxCertificateLength) { | 537 server_certificate.size() > media::limits::kMaxCertificateLength) { |
| 538 NOTREACHED(); | 538 NOTREACHED(); |
| 539 return; | 539 return; |
| 540 } | 540 } |
| 541 | 541 |
| 542 if (ppp_decryptor_impl_) { | 542 if (ppp_decryptor_impl_) { |
| 543 ScopedPPVar server_certificate_var( | 543 ScopedPPVar server_certificate_var( |
| 544 ScopedPPVar::PassRef(), | 544 ScopedPPVar::PassRef(), |
| 545 PpapiGlobals::Get() | 545 PpapiGlobals::Get() |
| 546 ->GetVarTracker() | 546 ->GetVarTracker() |
| 547 ->MakeArrayBufferPPVar(server_certificate.size(), | 547 ->MakeArrayBufferPPVar( |
| 548 &server_certificate[0])); | 548 static_cast<uint32_t>(server_certificate.size()), |
| 549 &server_certificate[0])); |
| 549 CallWhileUnlocked(ppp_decryptor_impl_->SetServerCertificate, | 550 CallWhileUnlocked(ppp_decryptor_impl_->SetServerCertificate, |
| 550 instance, | 551 instance, |
| 551 promise_id, | 552 promise_id, |
| 552 server_certificate_var.get()); | 553 server_certificate_var.get()); |
| 553 } | 554 } |
| 554 } | 555 } |
| 555 | 556 |
| 556 void PPP_ContentDecryptor_Private_Proxy::OnMsgCreateSessionAndGenerateRequest( | 557 void PPP_ContentDecryptor_Private_Proxy::OnMsgCreateSessionAndGenerateRequest( |
| 557 PP_Instance instance, | 558 PP_Instance instance, |
| 558 uint32_t promise_id, | 559 uint32_t promise_id, |
| (...skipping 177 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 736 ppp_decryptor_impl_->DecryptAndDecode, | 737 ppp_decryptor_impl_->DecryptAndDecode, |
| 737 instance, | 738 instance, |
| 738 decoder_type, | 739 decoder_type, |
| 739 plugin_resource.get(), | 740 plugin_resource.get(), |
| 740 &block_info); | 741 &block_info); |
| 741 } | 742 } |
| 742 } | 743 } |
| 743 | 744 |
| 744 } // namespace proxy | 745 } // namespace proxy |
| 745 } // namespace ppapi | 746 } // namespace ppapi |
| OLD | NEW |