There are 2 instances of these
The swapExactIn and swapExactOut functions did not add deadline protection on swap.
This can allow a miner delay your transaction from being mined until the swap transaction incurs maximum slippage that would allow the miner profit from the swap transaction through sandwich attack.
According to the Uniswap docs: 
During high price swings, a miner can delay the transaction as possible until it incurs maximum slippage since there is no unix timestamp supplied at which the swap transaction must revert.
Loss of asset through a combination of swap transaction delay and sandwich attack to profit from some slippage due to market swings.
Allow users to pass a deadline for example 20 minutes in the future at which a swap transaction must fail if it has not been executed.
This is handled by most swap frontends like Uniswap frontend. A user just gets to choose how many minutes in the future should be set as the deadline for the swap.
The user can select for example 20 minutes on the frontend and the frontend handles the calculation of the timestamp literal to be supplied to the swap function.
For example deadline is unix timestamp + 20 minutes.
unix timestamp = number of seconds from 1970 till the current moment = block.timestamp.
20 minutes = 20 * 60.
deadline = 2578383 + 1800  = 2579583 seconds.
