Fix -I issues for win32
[catagits/Catalyst-Devel.git] / lib / Catalyst / Restarter / Win32.pm
index 65a8e3e..fb24a23 100644 (file)
@@ -16,7 +16,7 @@ sub _fork_and_start {
 
     # This is totally hack-tastic, and is probably much slower, but it
     # does seem to work.
-    my @command = ( $^X, $0, grep { ! /^\-r/ } @{ $self->argv } );
+    my @command = ( $^X, map("-I$_", @INC), $0, grep { ! /^\-r/ } @{ $self->argv } );
 
     my $child = Proc::Background->new(@command);