10-01-2008
Quote:
Originally Posted by
stevexyz
If you're using Linux look at select_tut(2)...
Cheers,Steve
Thank you, didn't know that page. This really helped, since it confirmed my expectations
and prove all other posters here wrong (no offence)
EDIT: well, not about the thing with the first write after opening a file. But that is not that important anyway. And nobody disputed that
Last edited by calv; 10-01-2008 at 11:15 AM..
Reason: Added some stuff
10 More Discussions You Might Find Interesting
1. Programming
Hi,
Could you please tell me how can I know which position a given read descriptor ocuppies in the descriptors table.
I know that, for instance, 'stdin' ocuppies position ... what about the others descriptors that I create usings pipes or sockets??
Thanks!
P.S.: Sorry for my bad English (2 Replies)
Discussion started by: jnuno
2 Replies
2. Programming
How can 'popen()' be used for reading and writing to opening pipe?
If i try 'popen("prog", "rw")'
and then put and get chars - it does
not work.
What is wrong? (1 Reply)
Discussion started by: szzz
1 Replies
3. Shell Programming and Scripting
I have tried to show the file name whose size is greater than 200 byte in current directory.
Please help me.
ls -l | tr -s " " " " | cut -f 5,9 -d " " >out.txt
#set -a x `cat out.txt`
i=0
`cat out.txt` | while
do
read x
echo $x
#re=200
j=0
if }" < "200" ]
then
echo $j
j=`expr $j... (2 Replies)
Discussion started by: rinku
2 Replies
4. UNIX Desktop Questions & Answers
OK... I'm fairly new to unix having the admin handed to me on a platter w/almost no training.
However, being a programmer, I do pick up things fairly easily, but this one is getting the best of me.
I have a unix server that runs multiple versions of the same ERP system, hand crafted for our... (1 Reply)
Discussion started by: chimodel
1 Replies
5. Shell Programming and Scripting
I need to find all the files that have group Read or Write permission or files that have user write permission.
This is what I have so far:
find . -exec ls -l {} \; | awk '/-...rw..w./ {print $1 " " $3 " " $4 " " $9}'
It shows me all files where group read = true, group write = true... (5 Replies)
Discussion started by: shunter63
5 Replies
6. IP Networking
Hi,
We have smb client running on two of the linux boxes and smb server on another linux system. During a backup operation which uses smb, read of a file was allowed while write to the same file was going on.Also simultaneous writes to the same file were allowed.Following are the settings in the... (1 Reply)
Discussion started by: swatidas11
1 Replies
7. IP Networking
hi
am newbie to unix and socket programing
I am trying to figuring out syntax for read and write
to send data from server to client and client can read it
I have to send two integers
write(newsockfd,buffer,"%d %d",x,y,0) writing from client where x and y are two integers..
... (7 Replies)
Discussion started by: karthik1238
7 Replies
8. Shell Programming and Scripting
Hello Guys, How all are doing?
I have an issue in Unix and want help from all of you
I have a file in UNIX which it read by line by line , If at the end of line '0' is written the it should fetch that line into another file and change '0' to '1'
and If at the end of line '1' is written then it... (10 Replies)
Discussion started by: adisky123
10 Replies
9. Programming
Can someone help me to write this program in C in QNX?
Using the FIFO queues write a simple communication system consisting of programs write and read. The program write the parameters given strings enclosed in single quotes. These strings are written to the FIFO file. Reads the program read... (1 Reply)
Discussion started by: ebasse2
1 Replies
10. Shell Programming and Scripting
In the bash below the oldest folder in a directory is selected. If there are 3folders in the directory /home/cmccabe/Desktop/NGS/test and nothing is done to them (ie. no files deleted, renamed) then the bash correctly identifies f1 as the oldest. However, if something is done to the folder then... (4 Replies)
Discussion started by: cmccabe
4 Replies