Skip to content

Commit

Permalink
HADOOP-16167. Fixed Hadoop shell script for Ubuntu 18. Contributed by…
Browse files Browse the repository at this point in the history
… Daniel Templeton
  • Loading branch information
macroadster authored and PACordonnier committed Nov 7, 2023
1 parent 39dd4d8 commit eb5b434
Showing 1 changed file with 12 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2355,6 +2355,10 @@ function hadoop_verify_user_perm
declare command=$2
declare uvar

if [[ ${command} =~ \. ]]; then
return 1
fi

uvar=$(hadoop_build_custom_subcmd_var "${program}" "${command}" USER)

if [[ -n ${!uvar} ]]; then
Expand Down Expand Up @@ -2386,6 +2390,10 @@ function hadoop_need_reexec
return 1
fi

if [[ ${command} =~ \. ]]; then
return 1
fi

# if we have privilege, and the _USER is defined, and _USER is
# set to someone who isn't us, then yes, we should re-exec.
# otherwise no, don't re-exec and let the system deal with it.
Expand Down Expand Up @@ -2422,6 +2430,10 @@ function hadoop_subcommand_opts
return 1
fi

if [[ ${command} =~ \. ]]; then
return 1
fi

# bash 4 and up have built-in ways to upper and lower
# case the contents of vars. This is faster than
# calling tr.
Expand Down

0 comments on commit eb5b434

Please sign in to comment.