HDFS-16564. Use uint32_t for hdfs_find (#4245)
* hdfs_find uses u_int32_t type for storing the value for the max-depth command line argument. * The type u_int32_t isn't standard, isn't available on Windows and thus breaks cross-platform compatibility. We need to replace this with uint32_t which is available on all platforms since it's part of the C++ standard.
This commit is contained in:
parent
4230162a76
commit
d346be9bd2
|
@ -16,6 +16,7 @@
|
||||||
* limitations under the License.
|
* limitations under the License.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include <cstdint>
|
||||||
#include <future>
|
#include <future>
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
#include <memory>
|
#include <memory>
|
||||||
|
@ -40,7 +41,7 @@ bool Find::Initialize() {
|
||||||
"If provided, all results will be matching the NAME pattern otherwise, "
|
"If provided, all results will be matching the NAME pattern otherwise, "
|
||||||
"the implicit '*' will be used NAME allows wild-cards");
|
"the implicit '*' will be used NAME allows wild-cards");
|
||||||
add_options(
|
add_options(
|
||||||
"max-depth,m", po::value<u_int32_t>(),
|
"max-depth,m", po::value<uint32_t>(),
|
||||||
"If provided, the maximum depth to recurse after the end of the path is "
|
"If provided, the maximum depth to recurse after the end of the path is "
|
||||||
"reached will be limited by MAX_DEPTH otherwise, the maximum depth to "
|
"reached will be limited by MAX_DEPTH otherwise, the maximum depth to "
|
||||||
"recurse is unbound MAX_DEPTH can be set to 0 for pure globbing and "
|
"recurse is unbound MAX_DEPTH can be set to 0 for pure globbing and "
|
||||||
|
|
Loading…
Reference in New Issue