It is a missing change from the following patch.
With this patch, if 'rp' is never set above (because there is not ed->file) than all of these subsequent dereferences are going to crash ... eg: rp->drag->size.x, etc, etc will all cause crashes as 'rp' is declared NULL at the top.
ie: What happens when this function is called, but ed->file is NULL ??? Any access to 'rp' below is going to crash....