In case of master-rs collocation HBASE_ZNODE_FILE is overwritten by regionserver process in HRegionServer#handleReportForDutyResponse() here is how it looks on master server:
it contains regionserver znode path instead of String value of master's ServerName. This affects ZNodeClearer#clear() in way that will not clear master znode in case we detect master crash. At end this will extend failover time until master znode expires configured in zookeeper by maxSessionTimeout parameter (40s in my case).
I have notice this on mater branch but it can be case in other branches where we are collocating master and rs.