diff --git a/src/test/modules/test_shmem/t/001_late_shmem_alloc.pl b/src/test/modules/test_shmem/t/001_late_shmem_alloc.pl
index 06796a7934c..58acd1bc729 100644
--- a/src/test/modules/test_shmem/t/001_late_shmem_alloc.pl
+++ b/src/test/modules/test_shmem/t/001_late_shmem_alloc.pl
@@ -38,8 +38,7 @@ $res = $node->safe_psql("postgres",
 is($res, 1, 'attach after startup');
 
 # If the size doesn't match when attaching, you get an error
-my $stderr;
-(undef, undef, $stderr) =
+my (undef, undef, $stderr) =
   $node->psql("postgres", "SELECT test_shmem_register('test_shmem after startup', 25, 3);");
 like(
 	$stderr,
@@ -93,6 +92,7 @@ else
 	);
 }
 
+# clean up
 $node->stop;
 $node->adjust_conf('postgresql.conf', "shared_preload_libraries", undef);
 
