This paper presents a stochastic model for discrete-time trading in financial markets where trading costs are given by convex cost functions and portfolios are constrained by convex sets. The model does not assume the existence of a cash account (a perfectly liquid asset that can be traded without restrictions). In addition to classical frictionless markets and markets with transaction costs or bid-ask spreads, our framework covers markets with nonlinear illiquidity effects for large instantaneous trades. In the presence of nonlinearities, the classical notion of free lunch turns out to have two equally meaningful generalizations, a marginal and a scalable one. Using techniques of convex analysis we give martingale characterizations of both in the spirit of the fundamental theorem of asset pricing.