Hey everyone,

I'm attempting to write a program that will pipe and fork to have a parent and child process. Then the parent writes numbers to the pipe and the child either multiplies or divides the two numbers. For some reason my file I/O isn't working. It's supposed to keep a log of actions etc. Below is the bulk of my code. Any suggestions to get it working would be very much appreciated. What it does now is write the child log, but not the parent or output log.

I'm pretty sure its getting stuck in one of the while loops for some reason but I cant tell why. Any help?

121 posts and you still can't make a proper title? And you should know by now most of us won't help without posting code, nor will we download it.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.