Skip to content

Commit

Permalink
[core] Fix peer filter config being rejected because of endianness
Browse files Browse the repository at this point in the history
  • Loading branch information
yomnes0 authored and maxsharabayko committed Apr 11, 2023
1 parent 3982284 commit a991767
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions srtcore/core.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2835,6 +2835,9 @@ bool srt::CUDT::interpretSrtHandshake(const CHandShake& hs,
char target[CSrtConfig::MAX_PFILTER_LENGTH + 1];
memset((target), 0, CSrtConfig::MAX_PFILTER_LENGTH + 1);
memcpy((target), begin + 1, bytelen);
// Un-swap on big endian machines
ItoHLA((uint32_t *)target, (uint32_t *)target, blocklen);

string fltcfg = target;

HLOGC(cnlog.Debug,
Expand Down

0 comments on commit a991767

Please sign in to comment.