X-Git-Url: http://git.vanrenterghem.biz/git.ikiwiki.info.git/blobdiff_plain/d2911a20a6913e46035a8731acafba6faf5997f9..ed75653e4d1ebc9827601ab3649e1422f45ef338:/IkiWiki/Plugin/inline.pm diff --git a/IkiWiki/Plugin/inline.pm b/IkiWiki/Plugin/inline.pm index c734bd9a6..d7117b611 100644 --- a/IkiWiki/Plugin/inline.pm +++ b/IkiWiki/Plugin/inline.pm @@ -388,10 +388,19 @@ sub absolute_urls ($$) { #{{{ my $url=$baseurl; $url=~s/[^\/]+$//; - + + # what is the non path part of the url? + my $top_uri = URI->new($url); + $top_uri->path_query(""); # reset the path + my $urltop = $top_uri->as_string; + $content=~s/(param(content => $pcontent); } else { - my ($a, $b, $c, $d, $e, $f, $g, $size) = stat(srcfile($file)); + my $size=(srcfile_stat($file))[8]; my $mime="unknown"; eval q{use File::MimeInfo}; if (! $@) { @@ -496,7 +505,7 @@ sub pingurl (@) { #{{{ defined(my $pid = fork) or error("Can't fork: $!"); return if $pid; chdir '/'; - setsid() or error("Can't start a new session: $!"); + POSIX::setsid() or error("Can't start a new session: $!"); open STDIN, '/dev/null'; open STDOUT, '>/dev/null'; open STDERR, '>&STDOUT' or error("Can't dup stdout: $!");