akallabeth
8cc6582044
Unify struct definitions ( #7633 )
...
* Unified enum/struct definitions, fixed include issues
* Fixed mac compilation issues
* Added missing include
* Fixed windows server build warnings
* Fixed VS2010 build issue
* Removed unnecessary library linking
* Fixed ThreadPool WinXP compatibility
* Fixed pr review remarks
2022-02-14 14:59:22 +01:00
Armin Novak
17f530a866
Transport opaque
2021-09-09 08:36:01 +02:00
Armin Novak
5afa592244
Fixed cast-qual warnings
2021-08-24 11:10:51 +02:00
Armin Novak
fd08c77f7f
Fixed definition of config.h symbols
2021-06-28 15:06:30 +02:00
Armin Novak
2a91afb0cf
Added adjustable tcp connect timeout
2021-06-08 08:21:47 +02:00
Alexandr
cf2daeb01d
cleanup of https://github.com/FreeRDP/FreeRDP/pull/6448 ( #6455 )
...
* Implemented switchable transport layer
Co-authored-by: akallabeth <akallabeth@posteo.net>
2020-09-02 13:37:04 +02:00
Armin Novak
ff79636d33
TSG improvements
...
* Respect connection timeout during connect
* Better debug output
* Cleaned up data types,
2020-06-19 11:31:13 +02:00
akallabeth
e6d10041c1
Fix #6033 : freeaddrinfo must not be called with NULL arguments.
2020-04-09 14:26:46 +02:00
Armin Novak
895cb8f944
Added macro freerdp_set_last_error_if_not
...
This macro replaces the multiple instances where the current
error state is checked before setting an optional error state.
Signed-off-by: Armin Novak <armin.novak@thincast.com>
2020-01-09 10:34:27 +01:00
Armin Novak
7d252cdc8e
Added freerdp_set_last_error_ex function
...
This new function allows better logging of call locations
for errors. Additionally added freerdp_set_error_log macro
to record function, file and line the error was set.
Signed-off-by: Armin Novak <armin.novak@thincast.com>
2020-01-08 17:39:25 +01:00
Armin Novak
639174e7d3
Added configurable TcpKeepAliveDelay setting.
2019-11-07 16:07:18 +01:00
Armin Novak
09dd01a78f
Implemented configurable tcp keepalive and timeout detection
2019-11-07 13:03:33 +01:00
Armin Novak
72ca88f49c
Reformatted to new style
2019-11-07 10:53:54 +01:00
Armin Novak
f25488a7ab
Reset last error state after a hostname was resolved successfully.
2019-09-11 10:43:17 +02:00
Armin Novak
f51a9bafcc
Fixed sign-compare warnings
2019-04-05 09:13:24 +02:00
Armin Novak
5623a4761f
Fixed a possible NULL dereference.
2018-11-23 10:32:52 +01:00
akallabeth
d0d414dfa0
Fix #5059 : Changed return type of peer_free to void.
2018-11-22 19:08:25 +01:00
Armin Novak
8df39fdad4
Use blocking sockets in freerdp_tcp_connect_multi
...
The non blocking connect in freerdp_tcp_connect_multi did not
work reliably.
Fall back to blocking connect (which might take longer until the connection
is established) instead of not being able to connect at all.
2018-11-22 11:11:31 +01:00
Armin Novak
1ed436c8fc
Fixed socket cleanup in connect multi.
2018-11-22 11:11:31 +01:00
Armin Novak
4b3f4cc2fc
Fixed event check in freerdp_tcp_connect_multi
2018-11-22 11:11:31 +01:00
Armin Novak
5f4843191b
Replaced BIO_free with BIO_free_all
...
There is no point in using BIO_free with a custom recursion
to free up stacked BIOs if there is already BIO_free_all.
Using it consistently avoids memory leaks due to stacked BIOs
not being recursively freed.
2018-11-08 12:09:49 +01:00
Armin Novak
5eca5ebde8
Fixed #4993 : Allow uninitialized bio socket in transport_bio_simple_uninit
...
When the TLS connection is aborted early (certificate issues, ...)
the bio simple socket might not have been initialized.
Do not access the NULL pointer on cleanup.
2018-11-07 17:02:07 +01:00
Armin Novak
88d310ff2c
Fixed compiler warnings (casts, ...)
2018-10-18 09:09:30 +02:00
Armin Novak
47ba37fbcb
Unified dns resolving of host
2018-09-27 16:08:28 +02:00
Armin Novak
114abad767
Removed use of strcpy.
2018-08-27 14:34:09 +02:00
Ondrej Holy
1a413b5b4e
core/tcp: Prevent buffer overflow found by covscan
...
buffer_size_warning: Calling strncpy with a maximum size argument of 108 bytes on destination array "addr.sun_path" of size 108 bytes might leave the destination string unterminated.
2018-08-22 14:34:02 +02:00
Ondrej Holy
26bc52f79c
core/tcp: Format code by astyle
...
Run ./scripts/format_code.sh before the following changes.
2018-08-22 14:34:02 +02:00
Martin Fleisz
99346d19c6
Merge pull request #4611 from akallabeth/argument_warnings
...
Argument warnings
2018-05-04 10:06:42 +02:00
Armin Novak
5765e9a422
Fixed #4476 : broken casts/variable sizes for custom BIO calls.
2018-05-03 12:30:40 +02:00
Armin Novak
f631958a08
Fixed argument warning.
2018-05-02 13:08:17 +02:00
Martin Fleisz
855af9e941
Merge pull request #4557 from akallabeth/connect_error_fix
...
Set connection error if TCP connect fails.
2018-04-12 12:10:56 +02:00
Armin Novak
2fc31fcb37
Set connection error if TCP connect fails.
2018-04-11 09:09:23 +02:00
Andre Esteve
d240069b5e
Gateway (RDG) use same IP for both channels
2018-04-10 20:59:33 -07:00
Armin Novak
26d9957608
Fix pointer type mismatch struct sockaddr_storage* and struct sockaddr*
2018-04-05 10:47:50 +02:00
Martin Fleisz
ff8b2c1b0e
core: Fix IPv6 handling on Windows
...
On Windows the sockaddr struct is smaller than sockaddr_in6.
This causes getsockname to fail because the buffer is too small.
The new code uses sockaddr_storage which should be large enough to
hold any supported protocol address structure.
See: http://pubs.opengroup.org/onlinepubs/009696699/basedefs/sys/socket.h.html
2018-04-04 17:19:18 +02:00
Armin Novak
78de329f1f
Fixed IPv4/IPv6 to string
2018-02-08 17:26:31 +01:00
Armin Novak
7305828122
Fix #4239 : Various memory leaks
...
* Fixed all tests, now can be run with -DWITH_ADDRESS_SANITIZER=ON compiled.
* Enabled address sanitizer for nightly builds.
2017-12-12 11:40:48 +01:00
Armin Novak
2cc64298f2
Fix #4281 : Added option to prefer IPv6 over IPv4
2017-11-27 11:43:54 +01:00
Jura Sasek
4edb5cf7e6
Build for Solaris
2017-05-24 04:27:01 -07:00
Armin Novak
8250bbd6c8
Setting DNS error if lookup fails.
2016-12-19 13:49:40 +01:00
Norbert Federa
f71b6b46e8
fix string format specifiers
...
- fixed invalid, missing or additional arguments
- removed all type casts from arguments
- added missing (void*) typecasts for %p arguments
- use inttypes defines where appropriate
2016-12-16 13:48:43 +01:00
Norbert Federa
c6e6b44143
countless WLog/printf format specifier fixes
2016-11-25 17:06:25 +01:00
Norbert Federa
7befab856c
Support for OpenSSL 1.1.0
2016-11-24 17:50:09 +01:00
Armin Novak
9c64e77a84
Disabled thread local storage on iOS.
...
iOS does not support Thread Local Storage.
Disabling it for now until a solution is found.
Print a compiler warning informing developers about this issue.
2016-10-06 13:43:10 +02:00
akallabeth
7c5fcc9ee2
Merge pull request #3149 from bmiklautz/feb22
...
Misc fixes
2016-02-23 20:23:52 +01:00
Bernhard Miklautz
be02849ece
tcp: set the timeout to 9s
...
Set the TCP_USER_TIMEOUT to 9s as suggested by @giox069.
See #3015 for details
2016-02-23 15:40:20 +01:00
volth
8b9c40248a
Increase TCP_USER_TIMEOUT to avoid disconnections.
...
TCP_USER_TIMEOUT value is too small, it is only 4 seconds.
That causes random disconnections reported in the bug report https://github.com/FreeRDP/FreeRDP/issues/2802
This patch should fix the bug report https://github.com/FreeRDP/FreeRDP/issues/2802
2016-02-23 15:40:20 +01:00
Bernhard Miklautz
e6f013eac7
fix spelling
...
replace occured with occurred
Fixes #3142
2016-02-22 17:01:43 +01:00
Armin Novak
22f704c0a8
Fixed _socket error check.
2016-02-03 11:45:22 +01:00
Nito Martinez
2d5c78849e
Fix formatting: else if in its own line and no brackets for single statements
2015-11-26 09:50:03 +01:00