Leg swelling, or edema, in cancer patients can be caused by various factors. One common cause is the obstruction of the lymphatic system, known as lymphedema, which can occur when cancer spreads to or compresses the lymph nodes. Tumors in the pelvic or abdominal area can also obstruct blood flow, leading to swelling. Additionally, certain cancer treatments, such as surgery or radiation therapy, can damage lymph nodes and vessels, further contributing to swelling.