UNIX/Linux Programming - November 2009 (Page 2)

by MaxT
Raw Sockets - Connecting
 
Ok so the situation is this. For a coursework project I'm creating an application which helps to teach networking and data encapsulation to A-Level computer sci...
[1 reply] : There isn't because you are implementing TCP in user land. connect() ... (by jsmith)
Running single binary/process on linux/unix (1,2)
 
How do I make sure in my linux binary that I run only single instance of it on particular machine and or for particular user? so that if other second one is run...
[20 replies] Last: #include <iostream> #include <signal.h> using namespace std; //v... (by writetonsharma)
by CD4
segmentation fault...
 
#include<stdio.h> int main(int argc,char *argv ) { FILE *fp; if (argc==3){ fp=fopen(argv ,"w+"); fprintf(fp,"%s\n",argv ); } else { print...
[2 replies] Last: bazzy you are awesome.. you rock man.. what fool of me.. i as trying t... (by CD4)
Regarding STL Maps
 
Hi, I am developing a program where i have a map of very large size where the key value is a string.... I now have a string ....is there a way to directly sear...
[4 replies] Last: Do you have access to TR1 unordered containers? (by PanGalactic)
UNIX errno -> message conversion (1,2)
 
I just made this, and then I thought it might help some people, so I'm posting it here: /* For errno -> error conversion. An error's index is the correspond...
[24 replies] Last: I know, but I had to look up OJ ... it also means orange juice.And I w... (by DrChill)
counting word in a file using shell script
 
How would you count word in file. remember you can't use grep with wc because it won't count word coming twice in same line.
[12 replies] Last: you have done better than needed. e.g. "white dog may or may not run... (by reachvimalm)
any NIO java equivalent in C++
 
do we have any java nio equivalent class/ implementation in C++?
[1 reply] : No. (by kbw)
Issue in reading a binary file
 
Hi guys i have a problem while reading a binary file... I have written some data in binary format and want to read the data now... but when i print the data its...
[8 replies] Last: exactly...you got it correct. you dont have to do anything for char... (by writetonsharma)
Square-Root fuction
 
Hi there. Can somewone make me a program that calculates the square root of X without using the math.h header. Why: curiosity on how to do it. thanks in a...
[2 replies] Last: I was going to post something but then I realised he said square root... (by chrisname)
shell command
 
I am a little new to ubuntu & linux, How do I make a shell command compile my source code I surfed and surfed and surfed but the net has no flies (confusing-ish...
[4 replies] Last: you can use make. if your file is called main.cpp (or main.c) make ... (by bigearsbilly)
by devas
Mix C and C++
 
Hi, i have a question. Is it possible to write a code that callable both from C and C++? I want to write a logger which put some logs in a specific file a...
[4 replies] Last: Thank you (by devas)
Host name to IP Address (vice-versa)
 
Hi Guys, How can I convert hostname to IP address? localhost ---> 127.0.0.1 Thanks in advance
[1 reply] : Never mind found it. In case someone else is looking for it stri... (by kevinchkin)
segmentation violation????
 
Hello I have a problem while executing my code. It gave no error while compiling. The error i get is: *** Break *** segmentation violation (no debugging ...
[7 replies] Last: Segmentation fault occurs whenever your program tries to access INACCE... (by gajawadasatish)
November 2009 Pages: 12
  Archived months: [oct2009] [dec2009]

This is an archived page. To post a new message, go to the current page.