#!/usr/bin/perl -w use strict; my $config_file = "/home/foo/bar"; read_conf($config_file); # el fin # this subroutine in RL actually does something, # but that is outside the scope of the question ;) sub read_conf { my $conf_file = @_; open (CONF, "$conf_file") or die "[ $conf_file ]: $!\n"; }