Compare commits

..

No commits in common. "bb0ae8ac74db33f6c40ddecf445d2e66f3c182b7" and "9439b39631507d8cda6ea4aa9cf2e8972b695a89" have entirely different histories.

4 changed files with 8 additions and 52 deletions

View File

@ -1,31 +1,5 @@
# Changelog # Changelog
## Version 4.5.0
#### services
* btdrv: Missing definitions for ble were added
* capsdc: Updated for [17.0.0+]
* hidsys: Support was added for many commands
* fs:
* Updated for [17.0.0+]
* Support was added for many fsDeviceOperator commands
* ncm: Updated for [17.0.0+]
* nfc: Support was added for all remaining commands
* ns: Added nsEstimateSizeToMove
* pctl: Support was added for many commands
* ssl: Updated sslConnectionSetPrivateOption for [17.0.0+]
* ts: Updated for [17.0.0+]
#### devices
* socket: Updated wrapper to automatically select latest available bsd service version (fixes multicast support)
#### miscellaneous
* The linker script/crt0 were updated to support relro
* A bug was fixed in aes-cbc block decryption
* A number of problems were corrected involving incorrect ipc serialization with pointer arguments
**Several issues were fixed, and usability and stability were improved.**
## Version 4.4.2 ## Version 4.4.2
#### system #### system
@ -38,7 +12,7 @@
## Version 4.4.1 ## Version 4.4.1
#### miscellaneous #### miscellaneous
* add missing separator to local path * add missing separator to local path
**Several issues were fixed, and usability and stability were improved.** **Several issues were fixed, and usability and stability were improved.**

View File

@ -9,8 +9,8 @@ endif
include $(DEVKITPRO)/devkitA64/base_rules include $(DEVKITPRO)/devkitA64/base_rules
export LIBNX_MAJOR := 4 export LIBNX_MAJOR := 4
export LIBNX_MINOR := 5 export LIBNX_MINOR := 4
export LIBNX_PATCH := 0 export LIBNX_PATCH := 2
VERSION := $(LIBNX_MAJOR).$(LIBNX_MINOR).$(LIBNX_PATCH) VERSION := $(LIBNX_MAJOR).$(LIBNX_MINOR).$(LIBNX_PATCH)

View File

@ -10,6 +10,8 @@ typedef enum {
/// Configuration structure for socketInitalize /// Configuration structure for socketInitalize
typedef struct { typedef struct {
u32 bsdsockets_version; ///< Observed 1 on 2.0 LibAppletWeb, 2 on 3.0.
u32 tcp_tx_buf_size; ///< Size of the TCP transfer (send) buffer (initial or fixed). u32 tcp_tx_buf_size; ///< Size of the TCP transfer (send) buffer (initial or fixed).
u32 tcp_rx_buf_size; ///< Size of the TCP receive buffer (initial or fixed). u32 tcp_rx_buf_size; ///< Size of the TCP receive buffer (initial or fixed).
u32 tcp_tx_buf_max_size; ///< Maximum size of the TCP transfer (send) buffer. If it is 0, the size of the buffer is fixed to its initial value. u32 tcp_tx_buf_max_size; ///< Maximum size of the TCP transfer (send) buffer. If it is 0, the size of the buffer is fixed to its initial value.

View File

@ -62,6 +62,8 @@ static const devoptab_t g_socketDevoptab = {
}; };
static const SocketInitConfig g_defaultSocketInitConfig = { static const SocketInitConfig g_defaultSocketInitConfig = {
.bsdsockets_version = 1,
.tcp_tx_buf_size = 0x8000, .tcp_tx_buf_size = 0x8000,
.tcp_rx_buf_size = 0x10000, .tcp_rx_buf_size = 0x10000,
.tcp_tx_buf_max_size = 0x40000, .tcp_tx_buf_max_size = 0x40000,
@ -80,35 +82,13 @@ const SocketInitConfig *socketGetDefaultInitConfig(void) {
return &g_defaultSocketInitConfig; return &g_defaultSocketInitConfig;
} }
static u32 socketSelectVersion(void) {
if (hosversionBefore(3,0,0)) {
return 1;
} else if (hosversionBefore(4,0,0)) {
return 2;
} else if (hosversionBefore(5,0,0)) {
return 3;
} else if (hosversionBefore(6,0,0)) {
return 4;
} else if (hosversionBefore(8,0,0)) {
return 5;
} else if (hosversionBefore(9,0,0)) {
return 6;
} else if (hosversionBefore(13,0,0)) {
return 7;
} else if (hosversionBefore(16,0,0)) {
return 8;
} else /* latest known version */ {
return 9;
}
}
Result socketInitialize(const SocketInitConfig *config) { Result socketInitialize(const SocketInitConfig *config) {
Result ret = 0; Result ret = 0;
if (!config) if (!config)
config = &g_defaultSocketInitConfig; config = &g_defaultSocketInitConfig;
BsdInitConfig bcfg = { BsdInitConfig bcfg = {
.version = socketSelectVersion(), .version = config->bsdsockets_version,
.tcp_tx_buf_size = config->tcp_tx_buf_size, .tcp_tx_buf_size = config->tcp_tx_buf_size,
.tcp_rx_buf_size = config->tcp_rx_buf_size, .tcp_rx_buf_size = config->tcp_rx_buf_size,