A Canary can break its leg by getting it caught, or by being attacked by a wild bird through the wire etc.
If the lower leg / tarsometatarsus is broken cut a section of drinking straw about 15mm long (ie the length of the leg), slit the straw lengthwise and place around the leg and bind with a small amount of tape. Leave for about 3 weeks. During this period it is preferable to keep the bird as quiet as possible in a small cage without perches.
If the leg is broken to the point of being so damaged that the lower section is pale and obviously been without blood, it is time to call a Veterinarian or carry out an amputation. Same goes for toes.
To amputate use a sharp pair of sterile cutters (Sterilise your cutters by using disinfectant or by boiling) and sever the leg at the dead area. This may sound horrific but it is quite easy and in my experience not as painful as the injury that led to the amputation. Use an antiseptic on the cut and you should find that there will be little or no blood as the blood supply to the area below the cut has already ceased. As with a broken leg bind gently and keep the bird quiet for 3 weeks.
If the top part of the leg / tibiotarsus is broken (less likely) you can sometimes bind as per the lower leg, but often there is damage beneath the feathers which makes it more difficult to splint and you may need the Vet.