Look for the function doEdit() in wiki.cgi and look for the line
print &GetHistoryLink($id, T('View other revisions')) . "<br>\n";
And add the following two lines before this.
$revision = $Page{'revision'} if ($revision eq ''); print &GetOldPageLink("edit",$id,$revision-1,T('Revert to last revision')) . " | ";
You should have something like
print '<div class=wikifooter'>; $revision = $Page{'revision'} if ($revision eq ''); print &GetOldPageLink("edit",$id,$revision-1,T('Revert to last revision')) . " | "; print &GetHistoryLink($id, T('View other revisions')) . "<br>\n";
So now while editing, you can click on "Revert to last revision".