[Tile-serving] [openstreetmap/osm2pgsql] Fix multistage processing (take 2) (#1215)
Jochen Topf
notifications at github.com
Mon Jun 22 08:39:29 UTC 2020
@joto commented on this pull request.
> + return;
+ }
+
+ if (ltype != LUA_TTABLE) {
+ throw std::runtime_error{
+ "Table returned from mark_relation_members() contains 'ways' "
+ "field, but it isn't an array table"};
+ }
+
+ // Iterate over the 'ways' table to get all ids...
+ lua_pushnil(lua_state());
+ while (lua_next(lua_state(), -2) != 0) {
+ if (!lua_isnumber(lua_state(), -2)) {
+ throw std::runtime_error{
+ "Table returned from mark_relation_members() contains 'ways' "
+ "field, but it isn't an array table"};
The check is for the table key not the value. The table key is a number in "array tables", so we are checking the table is an array, not a hash.
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/osm2pgsql/pull/1215#discussion_r443402765
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/tile-serving/attachments/20200622/b2d315bc/attachment.htm>
More information about the Tile-serving
mailing list