Skip to content

Commit

Permalink
2024-01-29 17:13 UTC+0100 Przemyslaw Czerpak (druzus/at/poczta.onet.pl)
Browse files Browse the repository at this point in the history
  * src/harbour.def
    + added hb_socketNToHS() to exported functions

  * src/rtl/hbsocket.c
    + added hb_socketNToHS() for compilation without socket support
      (HB_SOCKET_OFF macro)
  • Loading branch information
druzus committed Jan 29, 2024
1 parent e71216e commit c892443
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 0 deletions.
8 changes: 8 additions & 0 deletions ChangeLog.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,14 @@
Entries may not always be in chronological/commit order.
See license at the end of file. */

2024-01-29 17:13 UTC+0100 Przemyslaw Czerpak (druzus/at/poczta.onet.pl)
* src/harbour.def
+ added hb_socketNToHS() to exported functions

* src/rtl/hbsocket.c
+ added hb_socketNToHS() for compilation without socket support
(HB_SOCKET_OFF macro)

2024-01-28 12:58 UTC+0100 Przemyslaw Czerpak (druzus/at/poczta.onet.pl)
* contrib/hbfimage/core.c
* use FreeImage_Rotate() instead of FreeImage_RotateClassic() in new
Expand Down
1 change: 1 addition & 0 deletions src/harbour.def
Original file line number Diff line number Diff line change
Expand Up @@ -3290,6 +3290,7 @@ hb_socketItemGet
hb_socketItemPut
hb_socketListen
hb_socketLocalAddr
hb_socketNToHS
hb_socketOpen
hb_socketParam
hb_socketRecv
Expand Down
9 changes: 9 additions & 0 deletions src/rtl/hbsocket.c
Original file line number Diff line number Diff line change
Expand Up @@ -435,6 +435,15 @@ int hb_socketInit( void ) { return -1; }

void hb_socketCleanup( void ) { ; }

HB_U16 hb_socketNToHS( HB_U16 netshort )
{
#if defined( HB_LITTLE_ENDIAN )
return HB_SWAP_UINT16( netshort );
#else
return netshort;
#endif
}

int hb_socketGetAddrFamily( const void * pSockAddr, unsigned len )
{
HB_SYMBOL_UNUSED( pSockAddr );
Expand Down

0 comments on commit c892443

Please sign in to comment.