This is the mail archive of the cygwin@sources.redhat.com 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]

Re: newbie: Out of order execution in script


Chris,

I'm the person who wrote and uses the "logon" function. I should say, "used to use," since I was unable to use it subsequent to one of my cygwin updates. Unfortunately, I cannot say exactly which update that was, but my recollection is that it stopped working when I upgraded to cygwin1.dll version 1.1.5. Subsequently updating to 1.1.6 did not cure the problem. I sometimes install experimental "Exp" releases, but I've never installed a snapshot.

I am also the person who sent the report you saw to Mr. Schwarz when an apparently similar problem was occurring to him (the "Out of order..." topic thread). At the time, my company's mail server was blocked due to an ORBS listing, so rather than just sit idly by and watch, I sent him my experience, including cygcheck output, some of which was then passed on to the list. I forget exactly where Larry Hall entered the conversation.


As I was preparing a response just now that detailed what I did, I found that the symptom no longer occurs. I have performed other updates, but based on the "cygcheck -s -v" output I saved form my message to Mr. Schwarz, it appears that I was running cygwin1.dll version 1.1.6 at the time:

  609k 2000/11/22 C:\cygwin\bin\cygwin1.dll - os=4.0 img=1.0 sys=4.0
                  "cygwin1.dll" v0.0 ts=2000/11/21 18:00
    Cygwin DLL version info:
        dll major: 1001
        dll minor: 6
        dll epoch: 19
        dll bad signal mask: 19005
        dll old termios: 5
        dll malloc env: 28
        api major: 0
        api minor: 30
        shared data: 3
        dll identifier: cygwin1
        mount registry: 2
        cygnus registry name: Cygnus Solutions
        cygwin registry name: Cygwin
        program options name: Program Options
        cygwin mount registry name: mounts v2
        cygdrive flags: cygdrive flags
        cygdrive prefix: cygdrive prefix
        cygdrive default prefix: 
        build date: Tue Nov 21 21:00:16 EST 2000
        shared id: cygwin1S3

This is the identical to what's produced by cygcheck right now. Since the BASH version variables are not exported by default, they're not in the saved cygcheck output. Here are the current values:

BASH_VERSINFO=([0]="2" [1]="04" [2]="0" [3]="8" [4]="release" [5]="i686-pc-cygwin")
BASH_VERSION='2.04.0(8)-release'

If this symptom shows up again, I'll submit a detailed report, but for now, I'll just consider myself thankful that I can go back to using my "logon" function. Thanks for looking into it and I'm sorry to put you out.

Randall Schulz
Teknowledge Corp.
Palo Alto, CA USA


At 19:06 12/2/2000, Christopher Faylor wrote:
>On Mon, Nov 27, 2000 at 09:34:44AM -0500, schwarza@gdls.com wrote:
>>
>>---------------------- Forwarded by Arthur I Schwarz/LS/GDYN on 11/27/2000
>>09:34 AM ---------------------------
>>
>>
>>Randall R Schulz <rschulz@teknowledge.com> on 11/22/2000 03:04:24 PM
>>
>>To:   schwarza@gdls.com, lhall@rfk.com, cygwin@cygwin.com
>>cc:
>>Subject:  Re: newbie: Out of order execution in script
>>
>>Hi,
>>
>>I've got an analogous problem under Windows 2000 Pro SP1. The problem
>>began occurring in previously working BASH function when I upgraded
>>to Cygwin 1.1.5. It is still happening in 1.1.6.
>>
>>Here's the shell function definition whose "side-effects" on the file
>>".logon" occur out of order:
>>
>>logon() {
>>           if [ -n "$(jobs)" ]; then
>>                     echo "There are stopped jobs." >&2
>>                     return 1
>>           fi
>>
>>           cd
>>           echo "#!/bin/sh" >|.logon
>>           cat  .env-initial >>.logon
>>           echo "exec /bin/bash --login -i" >> .logon
>>           exec -lc .logon
>>}
>>
>>After running this function the "exec /bin/bash --login -i" line is
>>the second line in the file (the #! line comes first). Here are the
>>first few lines of ".logon" after the logon function is executed:
>>
>>-==--==--==--==--==--==--==--==--==--==--==--==--==--==--==--==--==--==-
>>#!/bin/sh
>>exec /bin/bash --login -i
>>ALLUSERSPROFILE="C:\\Documents and Settings\\All Users"
>>APPDATA="C:\\Documents and Settings\\Randall R Schulz\\Application Data"
>>CLASSPATH="C:\\WINNT\\System32\\QTJava.zip"
>>COMMONPROGRAMFILES="C:\\Program Files\\Common Files"
>>COMPUTERNAME="CLEMENS"
>>COMSPEC="C:\\WINNT\\system32\\cmd.exe"
>>-==--==--==--==--==--==--==--==--==--==--==--==--==--==--==--==--==--==-
>
>How are you running this function?  I've tried this many many times on many
>different machines and I always get the desired effect.  I've tried creating
>a simple script with just that function and a "logon" and everything works
>correctly.  I've tried typing "logon" from bash and everything works.
>
>Is this function part of a .profile?  Do you just type 'logon' at the
>bash command prompt?
>
>Can you duplicate this problem under strace?
>
>strace -b16384 -osomefile -f bash
>
>If so, please send 'somefile' to this mailing list.
>
>Thanks.
>
>cgf
>
>--
>Want to unsubscribe from this list?
>Send a message to cygwin-unsubscribe@sourceware.cygnus.com



--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]