10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
So i am trying to read in file
readFile <GivenFile> modFile
looking for a regular file under the directories in the GivenFile and print them out is my over all goal.
basically I am looking for anything that looks like a directory in the given file and printing it out.
Since I am trying to do... (2 Replies)
Discussion started by: squidGreen
2 Replies
2. UNIX for Advanced & Expert Users
All of my machines (various open source derivatives on x86 and amd64) store argv above the stack (at a higher memory address). I am curious to learn if any systems store argv below the stack (at a lower memory address).
I am particularly interested in proprietary Unices, such as Solaris, HP-UX,... (9 Replies)
Discussion started by: alister
9 Replies
3. Programming
when i run my program, i have a parameter, that i want to set the value to another string
i am using
int main(int argc, char **argv) {
char my_str=argv;
printf("%s",my_str);
return 0;
}
and i get
Segmentation fault
ran using
./my_prog /usr/share/dict/words hello1
... (2 Replies)
Discussion started by: omega666
2 Replies
4. Programming
Hi,
Can somehelp help how to list file in a dir? (5 Replies)
Discussion started by: Learnerabc
5 Replies
5. UNIX for Dummies Questions & Answers
SCO openserver 5r5
I only have this available to me ...
To list the files...
cpio -itcvB < /dev/nrct0
To copy a file out
cpio -icvdBum filename < /dev/nrct0So cpio is to archive or "zip" files up??
and /dev/nrct0 is the tape drive ???
How can i list all the files inside... (2 Replies)
Discussion started by: khaos83_2000
2 Replies
6. Shell Programming and Scripting
this is in one of my scripts...
if ($#argv == 0) then
echo 'blah bla'
exit 0
endif
I want it to be something like this...
if ($#argv == 0 OR $argv >=3)
echo 'blah bla'
exit 0
endif
so when the arguments are none, or greater than three I want this "if then" to take over. how? I... (5 Replies)
Discussion started by: ajp7701
5 Replies
7. Programming
Hello Friends,
I got stuck with fgets () & rewind() function .. Please need help..
Actually I am doing a like,
The function should read lines from a txt file until the function is called..
If the data from the txt file ends then it goes to the top and then again when the function is called... (1 Reply)
Discussion started by: user_prady
1 Replies
8. Programming
Hi C experts,
I have the following code for adding command line option for a program
int main (argc, argv)
int argc;
char *argv;
{
char *mem_type; //memory type
char *name; //name of the memory
int addr; //address bits
int data; ... (5 Replies)
Discussion started by: return_user
5 Replies
9. UNIX for Dummies Questions & Answers
What is the function of rewind()? (2 Replies)
Discussion started by: tigerkin
2 Replies
10. Programming
I have a program which I wish to modify. It used to be run from the command line, but now I wish to change this so it can be used as a function.
The program has complex argument processing so I want to pass my paramters to as if it were being called by the OS as a program.
I have tried to... (2 Replies)
Discussion started by: mbb
2 Replies