Changeset 1024

Show
Ignore:
Timestamp:
08/01/08 07:44:33 (1 month ago)
Author:
MaierMan
Message:

fix metalink hash parsing

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/chrome/content/dta/manager/metalinker.js

    r993 r1024  
    203203                                        continue; 
    204204                                } 
    205                                 var hash = null;  
    206                                 var hashes = this._getNodes(file, 'ml:verification/ml:hash'); 
    207                                 for each (h in hashes) { 
    208                                         h = h.textContent.trim(); 
     205                                let hash = null;  
     206                                for each (let h in this._getNodes(file, 'ml:verification/ml:hash')) { 
    209207                                        try { 
    210                                                 h = new DTA_Hash(h, hashes[j].getAttribute('type')); 
     208                                                h = new DTA_Hash(h.textContent.trim(), h.getAttribute('type')); 
    211209                                                hash = h;                
    212210                                        } 
    213211                                        catch (ex) { 
    214                                                 Debug.log(h, ex); 
     212                                                Debug.log("Failed to parse hash: " + h.textContent.trim() + "/" + h.getAttribute('type'), ex); 
    215213                                        } 
    216214                                }