How do I upgrade my Bitcoin client? I am working with an older version of Bitcoin and want to upgrade to version .4.  Is there a specific way to do this?  I want to try to upgrade, but am paranoid that I could lose my wallet if I do something wrong.
First, you should backup your wallet.dat in case something goes wrong. The file is located in the data directory:


  Windows
  
  C:\Documents and Settings\YourUserName\Application data\Bitcoin (XP)
  
  C:\Users\YourUserName\Appdata\Roaming\Bitcoin (Vista and 7)


The easiest way to open your appdata folder is to press Windows Key-R, then type %appdata% and hit enter.


  Linux
  
  ~/.bitcoin/
  
  Mac
  
  ~/Library/Application Support/Bitcoin/


Then install the new version in the regular manner. The new client should use your previous settings (including the wallet and the blockchain data).
If, by some strange magic, your wallet gets corrupted, just copy your backup into the data folder.