Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6230109
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T09:41:21+00:00 2026-05-24T09:41:21+00:00

I am from Unix programming background and am facing a unique behavior/problem during porting

  • 0

I am from Unix programming background and am facing a unique behavior/problem during porting my system from Unix to Windows.
[I am pretty new to development on windows, so the below question may look too obvious.]

I am porting using mingw and the problem in question is regarding “system()” call provided in Unix and the WEXITSTATUS option.


Question

  1. In Unix, to execute any commands/scripts we have code that uses system() call. The same compiles in mingw – but I want to know if there are any change in behavior between the Unix and Windows version of system() call.
    The windows version of system() call is provided in stdlib of mingw, but am not able to get the exact behavior.

  2. My second question is regarding WEXITSTATUS. Generally, In Unix this is used along with system() command to get the status of the command executed.
    a. Can the same be done with system() of stdlib of mingw?
    b. How to achieve it?


Note :

I have read about createProcess and its subsequent usage in the net – But my idea is to continue with existing code (use system() call itself) and find an alternative to WEIXTSTATUS.


Thanks for your help/suggestion in advance.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-24T09:41:22+00:00Added an answer on May 24, 2026 at 9:41 am

    Look here for Win32 documentation on system: http://msdn.microsoft.com/en-us/library/277bwbdz%28v=VS.100%29.aspx

    Note that the system call is subject to the command interpreter on the system, and cmd.exe (Windows command interpreter) works differently than Unix Bash.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm porting an OpenCV 2.2 app from Unix (that works) onto Windows 7 64-bit
I am porting my application to windows from unix and I have run into
im coming from unix / server / c++ /java background with no GUI experience
Is anyone aware of a way of sftp'ing from Unix to Windows Thanks Damien
In Socket Programming, how will a Unix thread receive a Socket CLOSE event from
Is it possible to check for messages from Qpid queue from unix/windows console? Here
I'm studying UNIX programming and was experimenting with read/write system calls. I have a
I guess this question is directed at Linux/Unix system programming experts (unfortunately I am
I'm porting a C++ application from Unix and the original developer created several files
Well I have a strange problem while convert from unix timestamp to human representation

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.