There are varying definitions of sexism. The one I usually use is: "Attitudes, conditions, or behaviors that promote stereotyping of social roles based on gender."
Another common one is "the belief that one gender is inferior to another."
If you want to evaluate whether or not you were being sexist, first choose your definition. You were stereotyping the male role as "never receiving aid from girls", so in that sense you were being sexist.
You were not being sexist in the sense that you didn't especially treat their gender as inferior to males.
It is commonly assumed that sexism is only negative stereotypes, but really if you treat people significantly differently based solely on their gender, you are exhibiting a behavior that stereotypes the genders into different roles. In that sense, chivalry is inherently sexist. Showing a woman courtesy merely because she is a woman, is therefore sexist. I doubt any woman will call you on it however. (unless that woman is your girlfriend/spouse and you are showing undue courtesy to another woman)
Some women even lament the passing of such behaviors, because it has mostly positive results for them. In reality though, chivalry is a code of conduct stemming back to unenlightened times, when women were not highly regarded at all. A man's world, where might ruled the lands, and women could never be landowners.
I would recommend you do not be chivalrous, but rather be courteous, if you wish to avoid being sexist.
HANDY GUIDE
If you refuse to let a girl pay because she is a girl, that is sexist.
If you refuse to let a girl pay because you do not wish to impose, it is not.
If you refuse to let a girl pay because you do not borrow money on principle, then it is not.