Questions tagged [systems-programming]

System programming is the activity of computer programming system software. The primary distinguishing characteristic of systems programming when compared to application programming is that application programming aims to produce software which provides services to the user, whereas systems programming aims to produce software which provides services to the computer hardware.

Wiki:

System programming is a kind of computer programming which is intended to design a system software. Systems programming is used to produce such softwares which provide services to the computer hardware. thus It requires a greater extent of hardware compatibility.

Implementing certain parts in operating system and networking requires systems programming, for example implementing Paging (Virtual Memory) or a device driver for an operating system. A System programming language like C, PL360, BLISS, D is usually used to for systems programming".

Usage:

The tag can be used for all system programming related problems. Stackoverflow is a question-answer website for programming related problems, for theoretical and other problems you can ask your system programming problems on https://www.superuser.com and https://programmers.stackexchange.com/

Read more:

408 questions
1
vote
3 answers

How do I get the User's operating system?

I am writing a C program, part of which requires me to get the User's operating system. For example, to get the home directory I can do the following: const char *homedir; homedir = getpwuid(getuid())->pw_dir; printf("Home dir: %s\n",homedir); I…
Mutating Algorithm
  • 2,604
  • 2
  • 29
  • 66
1
vote
2 answers

How to modify Keyboard interrupt (under Windows XP) from a C++ Program?

We have been given a little project (As part of my OS course) to make a Windows program that modifies keyboard input, so that it transforms any lowercase character entered into an uppercase one (without using caps-lock) ! so when you type on the…
Rockr90
  • 35
  • 2
  • 5
1
vote
1 answer

Storing a hexadecimal number in an int

Trying to implementation of an absolute loader with input from : http://pastebin.com/k7VkA3xQ Output currently obtained : http://pastebin.com/FiYPMWrZ #include #include #include #include #include…
mrdoubtful
  • 429
  • 2
  • 7
  • 17
1
vote
2 answers

Why would my if(-f ) not be working?

When initially checking if ARGV[0] is a file or directory, it worked fine with accurate results. Then further down into sub files I try it again and it doesnt return anything. This may seem like a small silly question but Im a student and help on…
1
vote
1 answer

why "mov %crN, %eax" can be encoded when crN is not exist?

Intel manual volume 3, said that there's only CR0,2,3,4 + CR8 in 32E mode, and CR1 is reserved. But when I compile instruction in title, N could be any value < 16. I disassemble the obj file and found that it's encoded just follow reference when…
Qutard
  • 355
  • 2
  • 6
1
vote
3 answers

terminal goes down with all children even when SIGKILLed but normal processes don't do the same

I would like to have the same effect in my program as the bash(terminal) does when we kill it using SIGKILL. As we know that we cannot handle SIGKILL in our progams so when ever I kill my program its children are assigned to init process, there is…
mSatyam
  • 531
  • 7
  • 25
1
vote
1 answer

Find which page an address belongs to

I could find out the address of a buffer in memory trivially as follows :- int main() { char buffer[100]; printf("%p\n, buffer); } Is there any way I could print out the address of the page the buffer belongs to? [EDIT] I'm on a Linux machine,…
user277465
1
vote
2 answers

How to catch SIGINT and ignore it in the child process?

I have a main that runs program from the command line arguments. The command line program is forked and run in the child process. When SIGINT is sent, I want to catch it and ask the user to confirm that he/she want to quit. If yes, both parent and…
user3213348
  • 255
  • 1
  • 5
  • 14
1
vote
1 answer

Proper behaviour of a linux daemon

What behaviours define a well written Linux daemon? I read about the double fork, closing standard file descriptors, and so on, but I wonder if someone experienced in writing these things could give me the low down.
mkaito
  • 1,005
  • 1
  • 10
  • 19
1
vote
0 answers

invoke java web start from web (file-extension/mime-type associations)

I have created web start app (JNLP and jar file) it's already installed on my PC. No I need to run this application from the servlet. 1) question. Can I invoke my java web start application from servlet? I need to run this, on my PC, I don't need…
grep
  • 5,465
  • 12
  • 60
  • 112
1
vote
1 answer

Does DebugActiveProcess also track child processes?

Here's piece of code doing the main thing - attaching to an active process. Although it appears that child processes have not got caught as CREATE_PROCESS_DEBUG_EVENT in the switch. Only CREATE(EXIT)_THREAD_DEBUG_EVENT and LOAD_DLL_DEBUG_EVENT are…
Nelly
  • 131
  • 2
  • 12
1
vote
3 answers

Function not returning char correctly: error during compile

I am currently trying to write a simple Rock, Paper, Scissors program in C. The entire point of the assignment is to get familiar with using chars. Here is the code I currently have. It is incomplete, as I am stuck. #include int main() { …
1
vote
3 answers

Detect copy event on windows

can someone give me a piece of code or API on how I can monitor any copy event on window base OS using vb classic (vb 6.0). I want to trap the copy event let say a user is copying a file on a computer, how can I get the name of the file that is…
Edang Jeorlie
  • 303
  • 1
  • 6
  • 18
1
vote
1 answer

Writing C Shell with combination pipes and redirection

I am trying to implement a mini shell in C that will accept any combo of <,>,>>,|,&. I have it to where It reads commands and executes file redirection etc, however, I cannot seem to find a good tutorial through Google on how to program it to accept…
vt-cwalker
  • 795
  • 2
  • 16
  • 34
1
vote
3 answers

How can I searches files in current dir and the files in directories that under current dir?

The function searches the files in current directory. If It accrosses a directory, It gets in and again searches for file except the current '.' and the previous '..' directory. But It doesnt work how I want.It does not get in the next…
Sabri Meviş
  • 2,231
  • 1
  • 32
  • 38