forked from organicmaps/organicmaps-tmp
[new downloader] Fix warnings
This commit is contained in:
parent
1478c3cc53
commit
45b6192f3d
2 changed files with 6 additions and 4 deletions
|
@ -1777,22 +1777,24 @@ BookmarkAndCategory Framework::FindBookmark(UserMark const * mark) const
|
|||
{
|
||||
BookmarkAndCategory empty = MakeEmptyBookmarkAndCategory();
|
||||
BookmarkAndCategory result = empty;
|
||||
ASSERT_LESS_OR_EQUAL(GetBmCategoriesCount(), numeric_limits<int>::max(), ());
|
||||
for (size_t i = 0; i < GetBmCategoriesCount(); ++i)
|
||||
{
|
||||
if (mark->GetContainer() == GetBmCategory(i))
|
||||
{
|
||||
result.first = i;
|
||||
result.first = static_cast<int>(i);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
ASSERT(result.first != empty.first, ());
|
||||
BookmarkCategory const * cat = GetBmCategory(result.first);
|
||||
ASSERT_LESS_OR_EQUAL(cat->GetUserMarkCount(), numeric_limits<int>::max(), ());
|
||||
for (size_t i = 0; i < cat->GetUserMarkCount(); ++i)
|
||||
{
|
||||
if (mark == cat->GetUserMark(i))
|
||||
{
|
||||
result.second = i;
|
||||
result.second = static_cast<int>(i);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -32,7 +32,7 @@ TMwmSubtreeAttrs LoadGroupSingleMwmsImpl(int depth, json_t * group, ToDo & toDo)
|
|||
if (!id)
|
||||
MYTHROW(my::Json::Exception, ("LoadGroupImpl. Id is missing.", id));
|
||||
|
||||
size_t const nodeSize = static_cast<size_t>(json_integer_value(json_object_get(j, "s")));
|
||||
uint32_t const nodeSize = static_cast<uint32_t>(json_integer_value(json_object_get(j, "s")));
|
||||
// We expect that mwm and routing files should be less than 2GB.
|
||||
Country * addedNode = toDo(id, nodeSize, depth);
|
||||
|
||||
|
@ -150,7 +150,7 @@ class DoStoreCountriesSingleMwms
|
|||
public:
|
||||
DoStoreCountriesSingleMwms(TCountriesContainer & cont) : m_cont(cont) {}
|
||||
|
||||
Country * operator()(string const & id, size_t mapSize, int depth)
|
||||
Country * operator()(string const & id, uint32_t mapSize, int depth)
|
||||
{
|
||||
Country country(id);
|
||||
if (mapSize)
|
||||
|
|
Loading…
Add table
Reference in a new issue