In this scenario, the brokerage is a Dual Agent but there are separate agents of the brokerage representing the buyer and seller.
This situation is more common and acceptable if a separate agent of the same brokerage legitimately happened to be working with a buyer who became interested in a property listed by another agent of the same brokerage. This this case, you’d hope and assume that the two agents are not colluding and sharing information with each other against the interests of their clients. Furthermore, you’d hope that the brokerage which knows information about both sides of the deal stays neutral.
This situation is common with larger brokerages with many agents, and typically agents will have enough sense to remain loyal to their respective clients.