Skip to content

Commit

Permalink
Fix MJPEG processing for wallpanel project #248
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexxIT committed Feb 9, 2023
1 parent 2e4b28d commit 6a40039
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion pkg/mjpeg/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,11 @@ func (c *Client) startJPEG() error {
}

func (c *Client) startMJPEG(boundary string) error {
boundary = "--" + boundary
// some cameras add prefix to boundary header:
// https://github.com/TheTimeWalker/wallpanel-android
if !strings.HasPrefix(boundary, "--") {
boundary = "--" + boundary
}

r := bufio.NewReader(c.res.Body)
tp := textproto.NewReader(r)
Expand Down

0 comments on commit 6a40039

Please sign in to comment.