Can cops enter your house if they smell burning marijuana and tell you that it was for a "protective sweep"?

Question Details:

Yesterday I had 2 cops come to my house looking for my roommate who has a warrant. As they were asking me where my roommate was, they asked why they smelled "burning dope". They then started trying to walk through the door as I was shutting it and telling them they couldn't come in. The cops then proceeded to shove me out of the doorway and enter the house. They said that they had to do a "protective sweep" and looked in all the rooms. They then asked if we wanted to wait for a warrant or if we would let them search. Was this legal?

AttorneyPages.com Important Notice