get_fs_root(): add check for string overflow

Check the length of returned string and error out if it's too long.

While at it, use PATH_MAX for the string size, and declare len
as size_t as this is what strlen returns.

Signed-off-by: Kir Kolyshkin <kir@openvz.org>
1 file changed