Closed gonzoleeman closed 9 years ago
Thank you Lee and Olaf!
Indeed, I never tested target-isns on a big-endian architecture. I copied isns.c
from IET and the same code is also present in tgt, so you may want to report the bug to these projects as well.
Could you write a patch and send me a pull request please? This way, you and Olaf will get proper attribution for your work.
Thanks again!
Oops! I missed a line in that pull request. Can you please cancel it? I'll submit a new one.
Updated pull request sent.
Fixed by merging Lee's pull request https://github.com/cvubrugier/target-isns/pull/27
NOTE: This issue was actually found by Olaf Kirch.
The code in src/isns.c:isns_get_ip() is automatically converting from network order to host order with this code:
This worked fine on x86, but fails on big-endian architecture.
Instead, this code can be replaced with:
Which copies from network order to network order.