It depends what's written in your lease and what your landlord decides to do. Some just have some leasebreaking fee, and some keep your entire security deposit. However, you can get screwed if you sign a lease and the landlord doesn't re-rent the place. You're responsible for the rent until the landlord can re-rent it. This means they technically shouldn't hold any rent (like your first month), but they can claim they couldn't get rid of it sooner and hold it as long as they please. It then becomes a court battle in their jurisdiction. Fun huh?