Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. quagsire

    parsing Record

    Logic4Fun, From the code posted earlier it appears as if you assume that a line will have a maximum of 1027 chars. If there is more than 1027 chars in the line the code will treat it as more than one line. This may not be what you want. A second thing is that fgets reads 1 less byte than what...
  2. quagsire

    Help with fork() function !!

    From the man pages : int fflush (Stream) ... Parameters Stream Specifies the output stream From borland c++ : If the given stream has buffered output fflush writes the output for stream to the associated file. It is only in Visual C++ that it is specified that it will clear the input...
  3. quagsire

    Help with fork() function !!

    fflush only flush output streams. If you use fflush on input streams the behaviour is undefined. Mostly the fflush(stdin) will just be ignored.
  4. quagsire

    simple c++ socket server help

    Search Google for "Beej's Guide to Network Programming". This is a very good intro to socket programming for Unix/Linux.
  5. quagsire

    IT trainer as career

    I am doing programming (C/C++, Java, VB) and would like to train other people and transfer some of my knowledge to them.
  6. quagsire

    IT trainer as career

    Hi, Does anynody know where I can find info on becoming an IT trainer ? All help appreciated. Thanks.
  7. quagsire

    String to float and float to string?

    Do not use string = "124.35". Use strcpy(string, "124.35"). For char[] and char* you have to use strcpy, strncpy, memcpy or memmove. That should solve your problem. To convert float to char[] use sprintf : sprintf(string, "%f", 124.34);
  8. quagsire

    date function

    ... char fileName[15]; sprintf(fileName,"%04d%02d%02d", loc_time.tm_year, loc_time.tm_mon, loc_time.tm_mday); fp = fopen(fileName, "w"); ... Ex. the file will be named "20020807".
  9. quagsire

    replacing words in txt file ?

    Try using the following awk : cat infile | awk '{while (sub("/usr/local/mrtg-2/bin//mrtg","/usr/bin/mrtg",$0)==1); print($0)}' >outfile
  10. quagsire

    How to get memory usage by the program

    ps v pid Read the man pages on ps for what each column mean.
  11. quagsire

    Signals

    My program is receiving a lot of signal 20 (SIGCHLD), but has no children. When I run the program on a different box, I don't receive any signals. I am trying to find out where the signals originate from. I can block the signals, but then I will never know what causes it.
  12. quagsire

    Signals

    How do I get the source of a signal to my programs?

Part and Inventory Search

Back
Top