Frequently Asked Questions

If you have an answer to a question you think others will ask, feel free to add it here. If all you have is a question, you can post that too, and someone will try to answer it.

Can I get an extension on the homework?

No. Either the whole class gets an extension due to circumstances outside of their control (big undiscovered errors in assignment, or acts of the flying spaghetti monster), or there are no extensions. The reason is that homework solutions are posted online and discussed in class immediately after the submission deadline.

The cat ate my homework

No problem, just "svn checkout" your latest revision from the course repository. You did commit early and often, did you not?

What is the difference between shutdown() and close()?

Generally the difference between close() and shutdown() is: close() closes the socket id for the process but the connection is still opened if another process shares this socket id. The connection stays opened both for read and write, and sometimes this is very important. shutdown() breaks the connection for all processes sharing the socket id. Those who try to read will detect EOF, and those who try to write will reseive SIGPIPE, possibly delayed while the kernel socket buffer will be filled. Additionally, shutdown() has a second argument which denotes how to close the connection: 0 means to disable further reading, 1 to disable writing and 2 disables both. Borrowed from here.

Topic revision: r2 - 2009-09-09 - 03:43:54 - Main.jakob
Copyright 2016 The Board of Trustees
of the University of
Helping Women Faculty Advance
Funded by NSF