Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compile error C2036: 'void *': unknown size #3

Open
timi-liuliang opened this issue Oct 9, 2020 · 0 comments
Open

Compile error C2036: 'void *': unknown size #3

timi-liuliang opened this issue Oct 9, 2020 · 0 comments

Comments

@timi-liuliang
Copy link

timi-liuliang commented Oct 9, 2020

file [icns_png.c] line [57]

  /* copy new bytes to end of buffer */
  memcpy(_ref->data + _ref->offset, data, length);

the type of _ref->data is void*

And there are a lot of warnings when compiling with visual studio 2019

2>D:\Github\echo-dev\thirdparty\libicns\icns_element.c(82,42): warning C4018: '<': signed/unsigned mismatch
2>D:\Github\echo-dev\thirdparty\libicns\icns_element.c(104,54): warning C4018: '>': signed/unsigned mismatch
2>D:\Github\echo-dev\thirdparty\libicns\icns_element.c(214,42): warning C4018: '<': signed/unsigned mismatch
2>D:\Github\echo-dev\thirdparty\libicns\icns_element.c(254,21): warning C4018: '<': signed/unsigned mismatch
2>D:\Github\echo-dev\thirdparty\libicns\icns_element.c(359,42): warning C4018: '<': signed/unsigned mismatch
2>D:\Github\echo-dev\thirdparty\libicns\icns_element.c(396,21): warning C4018: '<': signed/unsigned mismatch
2>D:\Github\echo-dev\thirdparty\libicns\icns_element.c(585,39): warning C4244: '=': conversion from 'icns_uint64_t' to 'icns_size_t', possible loss of data
2>D:\Github\echo-dev\thirdparty\libicns\icns_element.c(588,61): warning C4244: 'function': conversion from 'icns_uint64_t' to 'icns_size_t', possible loss of data
2>D:\Github\echo-dev\thirdparty\libicns\icns_element.c(614,46): warning C4244: '=': conversion from 'icns_uint64_t' to 'icns_size_t', possible loss of data
2>D:\Github\echo-dev\thirdparty\libicns\icns_element.c(671,41): warning C4244: '=': conversion from 'icns_uint64_t' to 'icns_size_t', possible loss of data
2>icns_family.c
2>D:\Github\echo-dev\thirdparty\libicns\icns_family.c(93,20): warning C4018: '<': signed/unsigned mismatch
2>icns_image.c
2>D:\Github\echo-dev\thirdparty\libicns\icns_image.c(470,1): warning C4244: 'initializing': conversion from 'icns_uint64_t' to 'icns_size_t', possible loss of data
2>D:\Github\echo-dev\thirdparty\libicns\icns_image.c(624,42): warning C4244: '=': conversion from 'icns_uint64_t' to 'unsigned long', possible loss of data
2>D:\Github\echo-dev\thirdparty\libicns\icns_image.c(652,42): warning C4244: '=': conversion from 'icns_uint64_t' to 'unsigned long', possible loss of data
2>icns_io.c
2>D:\Github\echo-dev\thirdparty\libicns\icns_io.c(161,11): warning C4244: '=': conversion from 'uint16_t' to 'icns_byte_t', possible loss of data
2>D:\Github\echo-dev\thirdparty\libicns\icns_io.c(177,17): warning C4244: '=': conversion from 'uint64_t' to 'icns_byte_t', possible loss of data
2>D:\Github\echo-dev\thirdparty\libicns\icns_io.c(178,17): warning C4244: '=': conversion from 'uint64_t' to 'icns_byte_t', possible loss of data
2>D:\Github\echo-dev\thirdparty\libicns\icns_io.c(179,17): warning C4244: '=': conversion from 'uint64_t' to 'icns_byte_t', possible loss of data
2>D:\Github\echo-dev\thirdparty\libicns\icns_io.c(180,17): warning C4244: '=': conversion from 'uint64_t' to 'icns_byte_t', possible loss of data
2>D:\Github\echo-dev\thirdparty\libicns\icns_io.c(181,17): warning C4244: '=': conversion from 'uint64_t' to 'icns_byte_t', possible loss of data
2>D:\Github\echo-dev\thirdparty\libicns\icns_io.c(182,16): warning C4244: '=': conversion from 'uint64_t' to 'icns_byte_t', possible loss of data
2>D:\Github\echo-dev\thirdparty\libicns\icns_io.c(183,11): warning C4244: '=': conversion from 'uint64_t' to 'icns_byte_t', possible loss of data
2>D:\Github\echo-dev\thirdparty\libicns\icns_io.c(238,72): warning C4267: '=': conversion from 'size_t' to 'icns_size_t', possible loss of data
2>D:\Github\echo-dev\thirdparty\libicns\icns_io.c(248,77): warning C4267: '=': conversion from 'size_t' to 'icns_size_t', possible loss of data
2>D:\Github\echo-dev\thirdparty\libicns\icns_io.c(623,26): warning C4018: '<': signed/unsigned mismatch
2>D:\Github\echo-dev\thirdparty\libicns\icns_io.c(636,53): warning C4018: '>': signed/unsigned mismatch
2>D:\Github\echo-dev\thirdparty\libicns\icns_io.c(787,26): warning C4018: '<': signed/unsigned mismatch
2>D:\Github\echo-dev\thirdparty\libicns\icns_io.c(800,53): warning C4018: '>': signed/unsigned mismatch
2>D:\Github\echo-dev\thirdparty\libicns\icns_io.c(911,54): warning C4018: '>': signed/unsigned mismatch
2>D:\Github\echo-dev\thirdparty\libicns\icns_io.c(922,23): warning C4018: '<': signed/unsigned mismatch
2>icns_jp2.c
2>D:\Github\echo-dev\thirdparty\libicns\icns_jp2.c(944,45): warning C4018: '<': signed/unsigned mismatch
2>D:\Github\echo-dev\thirdparty\libicns\icns_jp2.c(954,28): warning C4018: '>=': signed/unsigned mismatch
2>icns_png.c
2>D:\Github\echo-dev\thirdparty\libicns\icns_png.c(145,47): warning C4267: '=': conversion from 'size_t' to 'int', possible loss of data
2>D:\Github\echo-dev\thirdparty\libicns\icns_png.c(162,20): warning C4018: '<': signed/unsigned mismatch
2>D:\Github\echo-dev\thirdparty\libicns\icns_png.c(299,31): warning C4267: '=': conversion from 'size_t' to 'icns_size_t', possible loss of data
2>D:\Github\echo-dev\thirdparty\libicns\icns_png.c(217,14): warning C4996: 'fopen': This function or variable may be unsafe. Consider using fopen_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
2>icns_rle24.c
2>D:\Github\echo-dev\thirdparty\libicns\icns_rle24.c(117,22): warning C4018: '<': signed/unsigned mismatch
2>D:\Github\echo-dev\thirdparty\libicns\icns_rle24.c(117,59): warning C4018: '<': signed/unsigned mismatch
2>D:\Github\echo-dev\thirdparty\libicns\icns_rle24.c(123,48): warning C4018: '<': signed/unsigned mismatch
2>D:\Github\echo-dev\thirdparty\libicns\icns_rle24.c(123,85): warning C4018: '<': signed/unsigned mismatch
2>D:\Github\echo-dev\thirdparty\libicns\icns_rle24.c(135,48): warning C4018: '<': signed/unsigned mismatch
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant