Ok I need to make this program to display "cal" 3 month(one month before and one month after) side by side, rather than just one single month it displays in any Linux/UNIX. I got it working to display 3 calendar by using "system(customCommand)" three times; but then it's not side by side.
I got some hint to use the following system cal...
Hey everyone.
I'm planning on writing a socket server in C++ running on a Mac. I've been searching through a great portion of the internet without any results. Anyone knows where to start? Or even got a basic source code?
Much appreciated.
...
I'm just curious...
How do you simulate randomness? How is it done in modern OS (Windows, Linux, etc.)?
Edit:
Okay, NOT JUST GENERATING RANDOM NUMBER, which can be just done with calling rand() functions in most high level programming languages.
But, I'm more concerned with how it is actually done in modern operating systems.
...
Is it possible to pause a process, save the memory contents to a file, and then later reload the file so you can continue the program?
Edit
I've been reading about this:
http://en.wikipedia.org/wiki/Setcontext
Is it possible to dump the contents of the struct, and somehow force malloc to allocate the same memory regions?
...
When using a synchronous I/O such as fread which is buffered, the read operations are
postponed and combined, I think that isn't done synchronously.
So what's the difference between a buffered synchronous I/O and an asynchronous I/O?
...
When I read a large file in the file system, can the cache improve the speed of
the operation?
I think there are two different answers:
1.Yes. Because cache can prefetch thus the performance gets improved.
2.No. Because the speed to read from cache is more faster than the speed to read from
disk, at the end we can find that the cach...
I really enjoy automating things to make life easier for my self. I have tried looking around on this site as well as just Googling my question but nothing has come up to even point me in the right direction. So here is my question. I would like to:
Disable (aka uncheck) Time to display list of operating system.
Set Time to display ...
Hi all!
I'm currently hacking on a new project, a web-app. But something's wrong, and I think it's Vistas fault, when I'm stress-testing the app, not all of the requests are answered.
The only thing I can think of is that the queue of incomming requests is getting too long, I've googled around, but can't find out how long the queue is,...
I created a Java application which is the only application active on a workstation. (Similar to a kiosk system)
The problem is that the application has to be up and running as fast as possible after starting the computer.
I'm wondering which one of the major operating systems can be configured to provide the shortest startup time?
I'm...
This is my code... I don't know why I'm get an error segment... could somebody explain the reason to me?
#include <iostream>
#include <string>
// Required by for routine
#include <sys/types.h>
#include <unistd.h>
using namespace std;
int globalVariable = 2;
main()
{
string sIdentifier;
int iStackVariable = 20;
pid_t p...
How much trust can I put in a standard computer running windows? To what certainty can I be sure it will run my code the way I wrote it? How can I be sure that if I declare something like "int j = 5;", j will alway be 5? Is there a way to measure trust in a standard x86 computer system? What kind of protections are there to make sure...
The Java runtime provides a set of standard system libraries for use by programs. To what extent are these libraries similar to the system calls of an operating system, and to what extent are they different???
...
Whenever the bootloader loads the operating system there is presumably only ONE program flow active, right? This would mean, one processor holds the instruction pointer and executes the commands it founds at the position the EIP register points to. At which point and how does the system start to exploit more processes and/or threads (no ...
Hi,
me and my schoolmate were tasked to come up with an idea for a project that would have something to do with simulating things that concern the operation system (e.g. animation of disk algorithms such as FCFS; implementing your own virtual file system- with FUSE for example etc.). The problem is that all of the mentioned ideas are a...
I am just curious about this.
I had a network folder open on one computer viewing the files in the folder. From another computer I opened the same folder on the network and deleted a file. On the first computer the deleted file immediate disappeared from the list.
The only way that I can think of how it knows that is that it is constan...
I am not well acquainted to the compiler magic. The act of transforming human-readable code (or the not really readable Assembly instructions) into machine code is, for me, rocket science combined with sorcery.
I will narrow down the subject of this question to Win32 executables (.exe). When I open these files up in a specialised viewer...
If I want to use completion port to get information from different thread ,
how can I design the structure of the program?How about the one below?
If I want to use a global function ,how can I set the mutexes ?
Main(){
for i in range NumOfThreads{
CreateIoCompletionPort()
CreatThread(ThreadFun)
}
}
ThreadFun(){
Whil...
operating systems related question dunno if i can ask here
but thought i would get proper explanation in this forum
when a process be exec in user context... wont the higher priority precesses in kernel context blocking the process in user context all the time...
it is hazy for me... the concepts
......
...
1.How to understand asynchronous io in Windows??
2.If I write/read something to the file using asynchronous io :
WriteFile();
ReadFile();
WriteFile();
How many threads does the OS generate to accomplish these task?
Do the 3 task run simultaneously and in multi-threading way
or run one after another just with different order?
3.Ca...
Duplicate of: http://stackoverflow.com/questions/774925/detect-when-users-take-screenshots-of-my-program
There are various ways to take screenshots of a running application in Windows. However, I hear that an application can be tailored such that it can notice when a screenshot is being taken of it, through some windows event handlers p...