Use the system tempdir instead of hardcoding /tmp.
authorMahlon E. Smith <mahlon@laika.com>
Tue, 16 Dec 2014 16:30:08 -0800
changeset 76 589332cac30b
parent 75 39012216a450
child 77 7b7810fee305
Use the system tempdir instead of hardcoding /tmp.
shelldap
--- a/shelldap	Thu Dec 04 14:15:24 2014 -0800
+++ b/shelldap	Tue Dec 16 16:30:08 2014 -0800
@@ -661,7 +661,7 @@
 	#
 	if ( $use_temp ) {
 		my ( undef, $fname ) =
-		  File::Temp::tempfile( 'shelldap_XXXXXXXX', SUFFIX => '.ldif', DIR => '/tmp', UNLINK => 1 );
+		  File::Temp::tempfile( 'shelldap_XXXXXXXX', SUFFIX => '.ldif', TMPDIR => 1, UNLINK => 1 );
 		$self->{'ldif'}	      = Net::LDAP::LDIF->new( $fname, 'w', sort => 1, wrap => 0 );
 		$self->{'ldif_fname'} = $fname;
 	}