X-Git-Url: http://git.chise.org/gitweb/?a=blobdiff_plain;ds=sidebyside;f=netinstall%2Fpostinstall.cc;h=23f656e1600ef6c9626258dab054f7edd071baf3;hb=8b2e8ef2dee7da2f0d4cea712b0fc55902c3cff7;hp=bf26f66dc714ee38b411bcf39758f963b4bbe96b;hpb=1ecbe603154527afa87c21523aedd8e3bda77c2f;p=chise%2Fxemacs-chise.git.1 diff --git a/netinstall/postinstall.cc b/netinstall/postinstall.cc index bf26f66..23f656e1 100644 --- a/netinstall/postinstall.cc +++ b/netinstall/postinstall.cc @@ -102,13 +102,19 @@ do_postinstall (HINSTANCE h) next_dialog = 0; char* cygroot = find_cygwin_root (&issystem); int i; - for (i=0; shells[i]; i++) + + sh = 0; + + if (cygroot) { - sh = backslash (concat (cygroot, shells[i], 0)); - if (_access (sh, 0) == 0) - break; - free (sh); - sh = 0; + for (i=0; shells[i]; i++) + { + sh = backslash (concat (cygroot, shells[i], 0)); + if (_access (sh, 0) == 0) + break; + free (sh); + sh = 0; + } } char old_path[_MAX_PATH];