That depends on the specifics of the environment, trail, and your pants.
Indeed, going "pantsless" for short periods can be less risky if your pants are already soaked-through, it's very humid, there's ice build-up, and there's little to no risk of skin abrasion from terrain traversal.
Indeed, going "pantsless" for short periods can be less risky if your pants are already soaked-through, it's very humid, there's ice build-up, and there's little to no risk of skin abrasion from terrain traversal.