I think she's always had the scar, this was from 2011 http://www.celebuzz.com/2011-03-31/exclusive-kendall-and-kylie-jenner-interview-your-questions-answered/
"Kylie, a few fans have noticed a scar on your leg, how did you get it? (From user: Jess)
Kylie: Yes, I do have a scar on my leg. When I was about 5 my sister and I were playing hide and seek and I hid inside this really tall-enclosed gate. After a while when my sister didn’t find me I had to climb up on this sharp pole sticking out from the gate. I slipped and the pole went into my leg. I tried pulling away to get the pole out but it just tore through my whole leg. It’s smaller now though because I grew! "