Assignment 1: Clarifications II

A few clarifications/tips related to Assignment 1.

  • You can assume that the browsers generate properly formatted HTTP requests. You only need to handle user errors, such as, when users enter a URL pointing to a non-existing file.
  • Beware of Runtime.exec(String[] cmdarray, String[] envp). If the standard environmental variables, such as HOME is missing from the parameter envp, the perl script will not run properly. The script expects that HOME to be set to the user’s home directory. The symptoms of this bug is that todo.pl tries to create a folder /a1/data, which it does not have permission to.
  • Beware of readline(). It returns only after it encounters a new line character. Note that neither HTTP request or response BODY guarantees that it ends with a new line character. If you use readline(), you may have to wait forever for it to return.
  • If you are ssh-ing into cs2105-z from Windows ssh client, you may have key mapping issues when you use vim. You can copy my .vimrc from ~ooiwt/.vimrc on cs2105-z, which maps the keys properly, to resolve this issue.

11 comments to Assignment 1: Clarifications II

  1. LIN BAOYU says:

    Dear Prof,

    After I copy the .vimrc, the backspace key cannot work

  2. yangshun says:

    Can I put WebServer.java in a ~/a1/src folder or must it be in ~/a1 ?

  3. Liu Dake says:

    Dear Prof,
    My unix account looks different from my friends’…
    I login with liu-dake@cs2105-z.comp.nus.edu.sg
    not A0105656@cs2105-z.comp.nus.edu.sg
    AND my account directory is /home/l/liu-dake/a1
    Is it okay? Or, how can I change my directory of unix account?

    Thank you very much

  4. Gupta Arpit Brij says:

    Dear Prof,

    Me and my teammate were not able to find any link/procedure to book the demo slots for the assignment.

    Could you please clarify/provide the link/procedure to book the slots.

    Thank you,

    Arpit

Leave a Reply