Problem with Terminal after changed permission to /usr/bin I was trying to install rake and rspec using ruby gems.  I changed read permissions on /usr/bin

Now my terminal window looks like this:

login(388,0x7fff73cd5310) malloc: * error for object 0x7fdb79c05290: pointer being freed was not allocated
* set a breakpoint in malloc_error_break to debug

[Process completed]
Given that you changed the read permissions on /usr/bin recursively, trying to restore the proper permissions through Terminal will not work - too many items in there have unique permissions. The best plan of action to remedy this I have is as follows.


Open Disk Utility and run Repair Permissions on your disk. This may restore the proper permissions on the files in /usr/bin.
Reboot into Recovery mode (hold the R key down during boot) and run Disk Utility there  attempting the same Repair Permissions.
If you have a Time Machine backup, restore your system from a time prior to making the permissions change. This would be accessed through Recovery mode.


Takeaway from this is never change permissions recursively on a directory unless you specifically know what you're doing.