osmo-bts[master]: oml.c: Fix use of htons instead of ntohs

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

Pau Espin Pedrol gerrit-no-reply at lists.osmocom.org
Mon Jan 8 10:33:47 UTC 2018


Patch Set 1:

> That's odd. How was it working before? Do we need corresponding fix
 > on the BSC side?

I'm always confused by bit/byte-order stuff, but afaiu in little-endian hosts, htons and ntohs are actually the same function which basically do a swap between first and second byte, so the result is the same if you use htons and ntohs, but from code reader point of view, ntohs makes more sense here and it's the one used in similar places in the same file.

-- 
To view, visit https://gerrit.osmocom.org/5675
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Icbf65f8a4b871b0fa2e84ad6cd2188d4e34f704b
Gerrit-PatchSet: 1
Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Owner: Pau Espin Pedrol <pespin at sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: Max <msuraev at sysmocom.de>
Gerrit-Reviewer: Pau Espin Pedrol <pespin at sysmocom.de>
Gerrit-HasComments: No



More information about the gerrit-log mailing list