Skip to content

Commit

Permalink
[backend] throw out identical appdata entries
Browse files Browse the repository at this point in the history
Thanks again DimStar.
  • Loading branch information
mlschroe committed Oct 7, 2014
1 parent 6da1748 commit bd97b63
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/backend/bs_publish
Original file line number Diff line number Diff line change
Expand Up @@ -1343,6 +1343,7 @@ sub publish {

my $appdatas;
my $appdatas_state;
my %appdatas_seen;

my %deltas; # XXX remove hack
my %deltainfos;
Expand Down Expand Up @@ -1389,7 +1390,10 @@ sub publish {
if ($bin =~ /-appdata.xml$/) {
# collect application data
my $appdataxml = readstr("$r/$bin", 1) || '';
$appdatas_state .= Digest::MD5::md5_hex($appdataxml);
my $appdatamd5 = Digest::MD5::md5_hex($appdataxml);
next if $appdatas_seen{$appdatamd5};
$appdatas_seen{$appdatamd5} = 1;
$appdatas_state .= $appdatamd5;
my $appdata;
eval {
$appdata = XML::Simple::XMLin($appdataxml, 'ForceArray' => 1);
Expand Down

0 comments on commit bd97b63

Please sign in to comment.