This may or may not apply to your example... according to google:
"If you sell a stock and repurchase it within 30 days (before or after the sale date), the Canada Revenue Agency considers it a "superficial loss" and you won't be able to use it to offset capital gains. ... The simplest solution is to wait 30 days before repurchasing the same stock."
The stock price can turn negative on you before you know it.
Koo