stat structure (from <sys/stat.h>) is conditionally defined
to have different layout and size depending on the defined macros.
The correct macro is defined in my_config.h, which means it MUST be
included first (or, at least before <features.h> - so, practically,
before including any system headers).
In ::position() federated needs to know an element before the
current ("data_cursor") in the single-linked list. Replace list
traversal for every ::position() call (which is O(n^2)) with remembering
the current element before it's advanced by mysql_fetch_row().
storage/federatedx/federatedx_io_mysql.cc:
mdev:5698
Federated uses SHOW TABLE STATUS LIKE for ::info().
For nonexisting remote table it doesn't fail, but returns an empty result set.
We need to fake the error in the handler.