Added a linked list implementation.
Added ERROR() and WARNING() for debugging.
Fix bug where we could run past the end of the friends list
Fix segfault when no broadcast device is found
Fix bug where file handle wasn't closed on success