akallabeth
fb5934007a
[doxygen] add basic documentation for new API
...
* Add basic documentation for new functions/structs/data types since
3.0.0
2024-09-12 20:09:19 +02:00
akallabeth
b980bf2e14
[winpr,clipboard] use endian safe bitmap read/write
2024-09-04 21:56:44 +02:00
akallabeth
ebbfe598dc
[winpr,utils] unify bitmap reading
...
* clipboard synthesizer needs to read the bitmap header, use the function
from utils/image
* check bitmap header in utils/image and abort if wrong
2024-09-04 09:07:18 +02:00
akallabeth
6a3564407e
[warnings] fix clang-tidy issues in winpr
2024-08-29 15:20:39 +02:00
akallabeth
15456e1ee1
[warnings] fix implicit widening conversion
2024-08-29 10:47:20 +02:00
akallabeth
1d33095500
[warnings] fix cert-err33-c
...
Fix unused return values, cast to void if on purpose
2024-08-29 10:19:27 +02:00
Armin Novak
17d44e847f
[coverity] fix various warnings
2024-08-21 09:47:34 +02:00
akallabeth
4b7727bd4e
[winpr,utils] fix PNG bpp extraction
2024-08-19 11:50:15 +02:00
akallabeth
7f84bd5c81
[winpr,utils] fix image stride calculation
2024-08-19 11:50:11 +02:00
akallabeth
b6db375b9b
[winpr,utils] fix libjpeg const cast
...
libjpeg API is not const correct, so we need to cast away const
fixes #10175
2024-05-12 20:30:25 +02:00
akallabeth
1b8221e5bf
[warnings] fix various minor warnings
2024-05-08 14:53:39 +02:00
akallabeth
71e78bedd7
[warnings] fixed sign and const
...
* fix various char/BYTE sign warnings
* fix various const warnings
* fix format string size_t
* remove unused CMake variables
2024-04-18 11:05:58 +02:00
akallabeth
d7ebec5a65
[tidy] move loop variable declaration to loop
2024-02-22 12:31:50 +01:00
Armin Novak
894474b161
[winpr,utils] improve winpr image API
...
* Add checks for bitmap read functions
* Add more unit tests
* Do not expose internals to WinPR
2024-02-22 09:33:59 +01:00
akallabeth
81d2c1f057
[clang-tidy] clang-analyzer-core.NullDereference
2024-02-15 11:49:16 +01:00
akallabeth
0ba995655d
[clang-tidy] cppcoreguidelines-init-variables
2024-02-15 11:49:16 +01:00
Armin Novak
70f12ac871
[winpr,image] use fuzzy compare
...
* Add winpr_image_equal_ex to allow comparison of lossy compressed
formats, ignoring color depth and alpha
* Adjust tests to utilize winpr_image_equal_ex
2024-02-14 19:04:50 +01:00
akallabeth
cbab66a249
[warnings] fix incompatible pointer types
2024-02-12 10:23:27 +01:00
akallabeth
b5660035ae
[winpr,image] add support for WebP, JPEG and libpng
2024-02-07 10:04:08 +01:00
Armin Novak
605b6b6233
[cmake] build using external lodepng
2023-07-26 20:19:46 +02:00
akallabeth
516668d02b
[fclose] ensure no invalid pointers are passed.
...
fclose has undefined behaviour for NULL pointers, so check for these.
2023-04-28 07:39:35 +02:00
akallabeth
8ed37e68d2
[stream] use logging capacity checks
2023-01-25 14:27:32 +01:00
akallabeth
784becd946
[winpr,image] add winpr_bitmap_write_ex
...
Added a helper function writing a bitmap from an image that has a stride
that is not width * <bytes per pixel>
2022-12-16 11:03:13 +01:00
Armin Novak
5476d48025
Use Stream_StaticInit for bitmap read
2022-10-10 15:29:45 +02:00
akallabeth
73cdcdfe09
Logging and parser fixes ( #7796 )
...
* Fixed remdesk settings pointer
* Fixed sign warnings in display_write_monitor_layout_pdu
* Use freerdp_abort_connect_context and freerdp_shall_disconnect_context
* Added and updates settings
* info assert/dynamic timezone
* mcs assert/log/flags
* Fixed and added assertions for wStream
* Unified stream length checks
* Added new function to check for lenght and log
* Replace all usages with this new function
* Cleaned up PER, added parser logging
* Cleaned up BER, added parser logging
* log messages
* Modified Stream_CheckAndLogRequiredLengthEx
* Allow custom format and options
* Add Stream_CheckAndLogRequiredLengthExVa for prepared va_list
* Improved Stream_CheckAndLogRequiredLength
* Now have log level adjustable
* Added function equivalents for existing logger
* Added a backtrace in case of a failure is detected
* Fixed public API input checks
2022-04-19 14:29:17 +02:00
Armin Novak
6ed50b4b1d
Refactored WinPR includes
2022-03-03 11:26:48 +01:00
Armin Novak
10e40147fb
Fixed various const warnings
2022-02-01 10:25:37 +00:00
akallabeth
3ccb96d52f
Fixed #7350 : Warnings with Stream_StaticInit
...
* Properly initialize the stream buffer
* Add Stream_StaticConstInit accepting a const buffer
* Modify API to return a pointer to the stream initialized
2021-10-14 12:11:16 +02:00
Armin Novak
610396e197
Fixed compilation warnings
...
Try to get the number of warnings down
2021-08-02 10:28:06 +02:00
Armin Novak
1af7ef2f1b
Fixed compilation warnings and typos
2021-06-16 15:21:56 +02:00
Armin Novak
f5bb6d12fc
Fixed compilation warnings
2021-06-16 14:26:06 +02:00
akallabeth
6b36c6d417
Replace fopen and path functions with wrappers ( #7043 )
...
Functions like fopen, PathFileExists, PathMakePath need to call
the wide character versions on windows for utf-8 support.
2021-05-31 11:42:03 +02:00
Marc-André Moreau
eb6777ea69
Fix Windows Unicode file path handling issues (+add winpr_fopen wrapper)
2021-05-26 08:40:29 +02:00
akallabeth
ad93ff3f0d
Fixed #6632
2020-12-06 14:48:21 +01:00
Kobi Mizrachi
920acd4c0e
winpr: image: add API to construct bmp header
2020-06-05 09:22:26 +02:00
akallabeth
dffd893dc5
Fixed integer overflow in winpr_image_bitmap_read_buffer
...
Thanks to hac425
2020-05-08 11:04:03 +02:00
Armin Novak
72ca88f49c
Reformatted to new style
2019-11-07 10:53:54 +01:00
kubistika
b3f78d2f4d
winpr: utils: image: fix const correctness
2019-10-24 12:19:31 +02:00
Armin Novak
0a9ef97a57
Fixed uninitialized variable.
2017-12-12 10:35:02 +01:00
Armin Novak
c91900dfb3
Fixed big endian issues with bitmap read.
2017-11-24 12:03:46 +01:00
Bernhard Miklautz
52fbfb7b12
fix clang warnings, directly include wtypes.h ( #4097 )
...
* build: clang use -Wno-unused-command-line-argument
With clang 5.0 builds are quite noisy otherwise.
* Directly include wtypes.h
Directly include winpr/wtypes.h where _fseeki64 or _ftelli64 is used.
* fix build warnings with clang 5
clang version: 5.0.0-svn310678-1~exp1 (branches/release_50)
Warning: parentheses-equality
* fix build warnings with clang 5
clang version: 5.0.0-svn310678-1~exp1 (branches/release_50)
Warning: tautological-compare
* fix build warnings with clang 5
clang version: 5.0.0-svn310678-1~exp1 (branches/release_50)
Warning:
incompatible pointer types passing 'size_t *' (aka 'unsigned
long *') to parameter of type 'UINT32 *' (aka 'unsigned int *')
[-Wincompatible-pointer-types]
2017-08-29 09:09:38 +02:00
Armin Novak
c3d4b7d262
fseeko and ftello for 64bit file support.
2017-08-14 08:42:49 +02:00
Armin Novak
b2c29158be
Scanbuild warning, argument checks and leak fixes.
...
* Added Stream_GetRemainingCapacity to check remaining stream size
before writes.
* Fixed shadow server memory leak.
* Fixed lots of scanbuild warnings
* Added missing argument checks in many functions
* Added missing static function declarations
2017-03-02 18:13:43 +01:00
David PHAM-VAN
3d22cbe2b8
Fix png image loading that needed write access
2016-01-27 11:02:16 -08:00
Armin Novak
5cad081cc8
Fixed memory leak.
2015-08-28 11:07:25 +02:00
Bernhard Miklautz
1cee185e3c
hardening: check fread and fwrite return values
2015-06-26 20:38:30 +02:00
Armin Novak
ad41fc59a3
Fixed reading bitmap from buffer.
2015-04-20 15:13:23 +02:00
Armin Novak
e5cdd8a299
Fixed bitmap reading bug.
2015-04-19 12:29:17 +02:00
Marc-André Moreau
334dec3c1f
winpr: add pragma pack, bitmap + clipboard definitions
2014-10-16 21:45:47 -04:00
Marc-André Moreau
abd87ace55
rdtk: initial commit
2014-09-29 16:08:08 -04:00