[from now] 2014/04/01 14:34:26

diff --git a/.zsh/z.sh b/.zsh/z.sh
index 8fd7f0a..b2955b0 100755
--- a/.zsh/z.sh
+++ b/.zsh/z.sh
@@ -107,7 +107,7 @@ _z() {
             -*) local opt=${1:1}; while [ "$opt" ]; do case ${opt:0:1} in
                     c) local fnd="^$PWD $fnd";;
                     h) echo "${_Z_CMD:-z} [-chlrtx] args" >&2; return;;
-                    x) sed -i "\:^${PWD}|.*:d" "$datafile";;
+                    x) sed -i -e "\:^${PWD}|.*:d" "$datafile";;
                     l) local list=1;;
                     r) local typ="rank";;
                     t) local typ="recent";;
@@ -219,7 +219,7 @@ if compctl >/dev/null 2>&1; then
             }
         fi
         [[ -n "${precmd_functions[(r)_z_precmd]}" ]] || {
-            precmd_functions+=(_z_precmd)
+            precmd_functions[$(($#precmd_functions+1))]=_z_precmd
         }
     }
     _z_zsh_tab_completion() {