bugGNUstep - Bugs: bug #29525, NSTask problem on windows

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #29525: NSTask problem on windows

Submitted by:  Riccardo Mottola <rmottola>
Submitted on:  Mon 12 Apr 2010 11:09:32 AM UTC  
 
Category: Base/FoundationSeverity: 4 - Important
Item Group: NoneStatus: Fixed
Privacy: PublicAssigned to: None
Open/Closed: Closed

Sun 18 Apr 2010 04:36:12 PM UTC, comment #4:

As far as I can tell things are working OK.

Richard Frith-Macdonald <CaS>
Project Member
Mon 12 Apr 2010 01:13:37 PM UTC, comment #3:

I think the microsoft documentation is misleading (ie our setting up of the command line argument to create a process is OK).

Certainly the existing code seems to work ... if you launch a task with a few arguments, and that task prints its arguments, the output matches the values set.

Most likely Riccardo's 'Parametro non corretto' refers to the path (MEM.EXE) being an invalid parameter to the CreateProcessW() function, rather than to an error in the command line we are using.

Richard Frith-Macdonald <CaS>
Project Member
Mon 12 Apr 2010 12:06:53 PM UTC, comment #2:

I think this is a faulty test ... I've changed it to run programs we created instead of mem.exe
I think the issue is that mem.exe is an old 16bit DOS program, and NSTask would need to refrain from setting the CREATE_NO_WINDOW flag (because 16 bit programs need a window to be created for them).
The problem is, if we create a window then it can get unpredictably displayed (we've had bug reports about that in the past) for unknown (to me at least) reasons .... messing up the display. Probably not supporting 16bit apps is the lesser of two evils, the current code is correct, and the test was wrong.

Richard Frith-Macdonald <CaS>
Project Member
Mon 12 Apr 2010 12:02:43 PM UTC, comment #1:

I think this is caused by us adding the program name to the arguments string. According to the specification http://msdn.microsoft.com/en-us/library/ms682425%28VS.85%29.aspx it sounds like we either have to leave out the application name parameter or provide only the arguments as the command line.

But then the documentation isn't that clear and I don#t have a Windows system to test this on at the moment.

Fred Kiefer <FredKiefer>
Project Member
Mon 12 Apr 2010 11:09:32 AM UTC, original submission:

there are problems with the arguments passed.

using the launch test in the base/NSTask suite:

Running base/NSTask/launch.m...
This is gnustep-make 2.2.0. Type 'make print-gnustep-make-help' for help.
2010-04-12 13:01:51.135 launch[1740] Error launching task: C:\WINDOWS\SYSTEM32\MEM.EXE ... Parametro non corretto.

(the error message means invalid parameter)

a simple test with execve() is able to start mem.exe directly.
Maybe it is a NSTask problem with the parameter array or a problem of CreateProcessW compared to execve?

Riccardo Mottola <rmottola>
Project Member

 

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by CaS (Posted a comment)
  • -unavailable- added by FredKiefer (Posted a comment)
  • -unavailable- added by rmottola (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 3 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Sun 18 Apr 2010 04:36:12 PM UTCCaSStatusNone=>Fixed
      Open/ClosedOpen=>Closed
    Mon 12 Apr 2010 11:09:45 AM UTCrmottolaSeverity3 - Normal=>4 - Important

    Back to the top


    Powered by Savane 3.1-cleanup1