sub doc_vorhanden { my ( $identnr, $daten_ref, @docnames ) = @_; ...