Hola Attila,
Both forms are interchangeable with one another. It is a feature of the subjuntivo imperfecto that there are two possible endings for the verb, and it works throughout all the singular and plural conjugations. It is possible that one has traditional Spanish roots and the other Latin, but I am not sure.
I have heard both used in Spain, and interchangeably by the same person, so it seems to be a matter of preference and / or perhaps the way the verb was originally learned. Here is a good link to a lesson.
Saludos. John
Conjugate Spanish verbs in the imperfect subjunctive tense (El Imperfecto de Subjuntivo)