Drop magic number in strrchr and strchr

Change-Id: Ic7391be8575eaaac76914dab62bc41c9773d703d