Merge remote branch 'upstream/develop' into develop-next

Conflicts:
	include/class.client.php
	include/class.usersession.php
Merge remote branch 'upstream/develop-next' into develop-next

Conflicts:
	include/class.client.php
	include/class.usersession.php
Merge pull request #565 from protich/feature/delivered-to+mailfetch

Add delivered-to detection to mail fetcher

Reviewed-By: Jared Hancock <jared@osticket.com>
Merge pull request #570 from greezybacon/issue/non-local-staff-pwreset

auth: Forbid password reset for non-local users

Reviewed-By: Peter Rotich <peter@osticket.com>
Merge remote branch 'upstream/develop' into develop-next
Merge remote branch 'upstream/develop-next' into develop-next
Destroy staff session on logout
Merge branch 'develop' into develop-next
Merge pull request #575 from greezybacon/issue/tnef-null-term-attach-names

tnef: Strip null bytes from attachment filenames

Reviewed-By: Peter Rotich <peter@osticket.com>
Merge pull request #576 from greezybacon/issue/attachment-charset

Careful transcoding attachments with a charset

Reviewed-By: Peter Rotich <peter@osticket.com>
lint: Add new stub functions
Merge branch 'develop' into develop-next

Conflicts:
	setup/test/tests/stubs.php
Place the message-id in the body of the email

This approach will help detect responses to the ticket thread from mail
clients which do not include the References and In-Reply-To MIME headers.
This also allows the Subject line to continue to omit the ticket number.