X-Git-Url: https://git.jankratochvil.net/?a=blobdiff_plain;f=src%2Fbundle.pl;h=ba30a484b4c57842885604c3a86630675b990654;hb=b2603c13d727c31f8366a86bd4b06fdc7fb2d3f5;hp=fdd252b6463e07244a9a52f81d136ac6bdfba1c0;hpb=c7f25cdcc123d8d4b062b5a96567dd961d156022;p=udpgate.git diff --git a/src/bundle.pl b/src/bundle.pl index fdd252b..ba30a48 100755 --- a/src/bundle.pl +++ b/src/bundle.pl @@ -42,6 +42,7 @@ print <<"EOH"; GHashTable *bundle_hash_new(void) { static GHashTable *hash; +/* Prefixed 32-bit network byte order file length. */ EOH my @files; for my $pathname (@ARGV) { @@ -57,6 +58,7 @@ for my $pathname (@ARGV) { "filename" =>$filename, "filename_sym"=>$filename_sym, }; + $F=pack("N*",length($F)).$F; # Prefix 32-bit network byte order file length. my $Fout=unpack "H*",$F; $Fout=~s/../0x$&,/g; $Fout=~s/(?:.....){1,16}/\t\t$&\n/g;