Skip to content

Commit

Permalink
Check httper_headers pointer when creating media player
Browse files Browse the repository at this point in the history
  • Loading branch information
xiaowei-guan committed Feb 1, 2024
1 parent cf47694 commit c736552
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
4 changes: 4 additions & 0 deletions packages/video_player_avplay/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## NEXT

* Check httper_headers pointer when creating media player.

## 0.3.1

* Resolve drm manager proxy doesn't support multiple instances issue.
Expand Down
3 changes: 2 additions & 1 deletion packages/video_player_avplay/tizen/src/media_player.cc
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,8 @@ int64_t MediaPlayer::Create(const std::string &uri,
return -1;
}

if (!create_message.http_headers()->empty()) {
if (create_message.http_headers() != nullptr &&
!create_message.http_headers()->empty()) {
std::string cookie = flutter_common::GetValue(create_message.http_headers(),
"Cookie", std::string());
if (!cookie.empty()) {
Expand Down

0 comments on commit c736552

Please sign in to comment.