Airlines work to make sure there is no duplicate callsigns in the same area at the same time. But there is no regulation for time between the reuse of a callsign.
They achieve this by either a callsign being used only once per day or with enough time between flights that there is no chance for both flights in the air at the same time.
The issue comes if two aircraft are in the air with the same callsign. The air traffic control systems will not be able to tell an ATS message (e.g.
CNG) for one aircraft from an ATS message from the other aircraft with the same callsign. Plus many other issues.
So if an airline needs to use the same callsign twice, like if the first flight is really delayed, they tend to append a letter to the end of the callsign, for example
Not asked but for completeness; there is also a risk if the callsigns are close but not the same, for example United 222 and United 232, there could be confusion between the aircraft over the radio. In these situations the air traffic controller can change the callsign to make sure there is no confusion. This could be while they are in the same airspace or for the entire flight.
The risk of callsign confusion has been documented many times in many incidents around the world. e.g. May 10, 2004 near Julian, California Callsign Confusion