Many states have exceptions for children on public transit and sometimes even in taxicabs and/or limosuines. You would have to check your own state's law or local municipal laws to be sure.
As for safety, on a full size city bus, an unrestrained child may not be "unsafe", but that would depend on the age and size of the child and other factors. Certainly unrestrained is almost always less safe than being properly restrained, but of course that isn't possible in every case.
Many factors that cause crashes in cars apply much less to buses. For example, bus drivers know their routes and aren't distracted by GPS, unknown roads, they don't drive drunk, etc. Buses are very visible and generally much more likely to be seen by other vehicles to avoid a crash. Also, in a crash, full size buses, like full size school buses, also have a major advantage in mass if they collide with a passenger vehicle. That means it is less likely to have injuries to passengers on the bus. Obviously there are exceptions. Rollovers are always bad for any unrestrained passenger in any type of vehicle.
It is still safer to have young children in an appropriate child restraint on a school bus or any bus if a suitable seatbelt system is available. How much safer is unknown as I have not seen any recent and compelling data.