- mkdir "${SOCKET_DIR}" $(id -u)
- chmod 700 "${SOCKET_DIR}"
- }
-
- check_create_socket_dir ()
- {
- if ! check_for_socket_dir; then
- create_socket_dir ||
- (echo "Couldn't create socket directory at ${SOCKET_DIR}" >&2 && exit 1)
- elif ! check_socket_dir_owner_and_perm; then
- (echo "Incorrect permissions at ${SOCKET_DIR}" >&2 && exit 1)
- fi