This is the mail archive of the cygwin-apps mailing list for the Cygwin project.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
Other format: | [Raw text] |
Charles Wilson wrote: > Notice anything? I'll try again Monday with the actually ::run command > modified... It turns out I was able to reproduce both error and success at home, without relying any details of the corporate network. If you actually invoke the outer bash using --norc --noprofile, you get the expected (desired) behavior. I'll need to verify that it really truly solves the problem Monday at work, but it looks promising. What is interesting is: case #1) invoke setup-diags-without-norc.exe by double-clicking it (Vista, non-admin user): I get the UAC dialog, it switches to Adminstrator, and I get the "bad" result (case1-log-fragment). case #2) invoke setup-diags-without-norc.exe from an existing shell, that itself was started from a non-Admin account, but using Run As, triggering UAC to Administrator: "good" result. Administrator[1.7] /usr/src/devel/setup/build $ ./setup-diags-without-norc.exe > case2-log-fragment case #3) invoke setup-diags-without-norc.exe from an existing shell as a normal user: Can't run it because windows wants UAC, but IIRC cygwin can't do this delegation, so fails. user[1.7] /usr/src/devel/setup/build $ ./setup-diags-without-norc.exe bash: ./setup-diags-without-norc.exe: Permission denied case #4) invoke setup-diags-WITH-norc.exe by double-clicking it (Vista, non-admin user): I get the UAC dialog, it switches to Adminstrator, and I get the "good" result (case4-log-fragment). case #5) invoke setup-diags-WITH-norc.exe from an existing shell, that itself was started from a non-Admin account, but using Run As, triggering UAC to Administrator: "good" result. Administrator[1.7] /usr/src/devel/setup/build $ ./setup-diags-with-norc.exe > case5-log-fragment case #6) invoke setup-diags-WITH-norc.exe from an existing shell as a normal user: as expected from case #3, this fails too. user[1.7] /usr/src/devel/setup/build $ ./setup-diags-with-norc.exe bash: ./setup-diags-with-norc.exe: Permission denied All of this is expected, except for case 2. However, with the attached patch we'll always been in case4 thru case6, so I'm not sure that matters. Checking in as obvious (Corinna *meant* to do this, but missed) 2009-05-30 Charles Wilson <...> * script.cc (Script::run): Really start bash with --norc --noprofile options. This doesn't appear to *break* anything, but I won't *know* if it actually solves the original problem until I check it on Monday. (I *think* it will, but...) -- Chuck
Index: script.cc =================================================================== RCS file: /cvs/cygwin-apps/setup/script.cc,v retrieving revision 2.29 diff -u -p -r2.29 script.cc --- script.cc 13 May 2009 11:44:32 -0000 2.29 +++ script.cc 30 May 2009 21:43:11 -0000 @@ -224,7 +224,7 @@ Script::run() const if (sh.size() && stricmp (extension(), ".sh") == 0) { log(LOG_PLAIN) << "running: " << sh << " --norc --noprofile -c " << scriptName << endLog; - retval = ::run (sh.c_str(), "-c", scriptName.c_str(), file_out); + retval = ::run (sh.c_str(), "--norc --noprofile -c", scriptName.c_str(), file_out); } else if (cmd && stricmp (extension(), ".bat") == 0) {
Attachment:
setup-log-fragments.tar.bz2
Description: Binary data
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |