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

[tests] use correct storage size #15855

Merged
merged 2 commits into from Apr 2, 2019

Conversation

Projects
None yet
3 participants
@olafhering
Copy link
Contributor

commented Apr 1, 2019

Description

Motivation and Context

How Has This Been Tested?

Screenshots (if appropriate):

Types of change

  • [x ] Bug fix (non-breaking change which fixes an issue)
  • Clean up (non-breaking change which removes non-working, unmaintained functionality)
  • Improvement (non-breaking change which improves existing functionality)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that will cause existing functionality to change)
  • Cosmetic change (non-breaking change that doesn't touch code)
  • None of the above (please explain below)

Checklist:

  • My code follows the Code Guidelines of this project
  • My change requires a change to the documentation, either Doxygen or wiki
  • I have updated the documentation accordingly
  • I have read the Contributing document
  • I have added tests to cover my change
  • All new and existing tests passed
[tests] use correct storage type for results from StringUtils
Reduce noise in build output.

d:\win-64\xbmc\utils\test\teststringutils.cpp(335): warning C4267: '=': conversion from 'size_t' to 'int'
d:\win-64\xbmc\utils\test\teststringutils.cpp(397): warning C4267: '=': conversion from 'size_t' to 'int'
d:\win-64\xbmc\utils\test\teststringutils.cpp(399): warning C4267: '=': conversion from 'size_t' to 'int'
d:\win-64\xbmc\utils\test\teststringutils.cpp(401): warning C4267: '=': conversion from 'size_t' to 'int'
d:\win-64\xbmc\utils\test\teststringutils.cpp(404): warning C4267: '=': conversion from 'size_t' to 'int'
d:\win-64\xbmc\utils\test\teststringutils.cpp(406): warning C4267: '=': conversion from 'size_t' to 'int'
d:\win-64\xbmc\utils\test\teststringutils.cpp(408): warning C4267: '=': conversion from 'size_t' to 'int'
d:\win-64\xbmc\utils\test\teststringutils.cpp(410): warning C4267: '=': conversion from 'size_t' to 'int'
d:\win-64\xbmc\utils\test\teststringutils.cpp(419): warning C4267: '=': conversion from 'size_t' to 'int'
d:\win-64\xbmc\utils\test\teststringutils.cpp(421): warning C4267: '=': conversion from 'size_t' to 'int'
d:\win-64\xbmc\utils\test\teststringutils.cpp(423): warning C4267: '=': conversion from 'size_t' to 'int'
d:\win-64\xbmc\utils\test\teststringutils.cpp(426): warning C4267: '=': conversion from 'size_t' to 'int'

Signed-off-by: Olaf Hering <olaf@aepfle.de>

@olafhering olafhering changed the title Test string utils [tests] use correct storage size Apr 1, 2019

@olafhering olafhering force-pushed the olafhering:TestStringUtils branch 3 times, most recently from ce12408 to be721e1 Apr 2, 2019

[tests] use correct storage type for results from XFILE::CFile
Reduce noise in build output.

d:\win-64\xbmc\utils\test\testregexp.cpp(155): warning C4244: '=': conversion from 'ssize_t' to 'unsigned int',
d:\win-64\xbmc\utils\test\testlog.cpp(105): warning C4244: '=': conversion from 'ssize_t' to 'unsigned int'
d:\win-64\xbmc\test\testutils.cpp(142): warning C4244: '=': conversion from 'ssize_t' to 'unsigned int',
d:\win-64\xbmc\filesystem\test\testzipfile.cpp(185): warning C4244: '=': conversion from 'ssize_t' to 'unsigned int',
d:\win-64\xbmc\filesystem\test\testfilefactory.cpp(75): warning C4244: '=': conversion from 'ssize_t' to 'unsigned int'
d:\win-64\xbmc\filesystem\test\testfilefactory.cpp(120): warning C4244: '=': conversion from 'ssize_t' to 'unsigned int',
d:\win-64\xbmc\filesystem\test\testfilefactory.cpp(136): warning C4244: '=': conversion from 'ssize_t' to 'unsigned int'
d:\win-64\xbmc\filesystem\test\testfile.cpp(22): warning C4267: 'initializing': conversion from 'size_t' to 'int'
d:\win-64\xbmc\filesystem\test\testfile.cpp(42): warning C4267: '=': conversion from 'size_t' to 'int'
d:\win-64\xbmc\filesystem\test\testfile.cpp(46): warning C4267: '+=': conversion from 'size_t' to 'int'
d:\win-64\xbmc\filesystem\test\testfile.cpp(54): warning C4267: '+=': conversion from 'size_t' to 'int'
d:\win-64\xbmc\filesystem\test\testfile.cpp(62): warning C4267: '+=': conversion from 'size_t' to 'int'
d:\win-64\xbmc\filesystem\test\testfile.cpp(65): warning C4267: '=': conversion from 'size_t' to 'int'
d:\win-64\xbmc\filesystem\test\testfile.cpp(70): warning C4267: '+=': conversion from 'size_t' to 'int'
d:\win-64\xbmc\filesystem\test\testfile.cpp(80): warning C4267: '+=': conversion from 'size_t' to 'int'

Add cast to sizeof() result to fix this warning:
warning: comparison between signed and unsigned integer expressions

Signed-off-by: Olaf Hering <olaf@aepfle.de>

@olafhering olafhering force-pushed the olafhering:TestStringUtils branch from be721e1 to 0c0016e Apr 2, 2019

@olafhering

This comment has been minimized.

Copy link
Contributor Author

commented Apr 2, 2019

Updated with static_cast. Android builds are broken, looks unrelated to my change.

@pkerling

This comment has been minimized.

Copy link
Member

commented Apr 2, 2019

More size_t is always welcome. Thanks. Let's try android once more.

@pkerling

This comment has been minimized.

Copy link
Member

commented Apr 2, 2019

jenkins build and merge

@pkerling pkerling added this to the Leia 18.2-rc1 milestone Apr 2, 2019

@jenkins4kodi jenkins4kodi merged commit f810028 into xbmc:master Apr 2, 2019

1 check was pending

default Found some time, building it now.
Details

@olafhering olafhering deleted the olafhering:TestStringUtils branch Apr 2, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.