]> git.cryptolib.org Git - arm-crypto-lib.git/blobdiff - host/nessie_check.rb
fixing sha256
[arm-crypto-lib.git] / host / nessie_check.rb
index 33eb4a383447dcb67cf10f6d0d6e663abef45dad..db69483f26f3dce72941d847f62b0cd03e2b5633 100644 (file)
@@ -1,7 +1,7 @@
 #!/usr/bin/ruby
 # nessie_check.rb
 =begin
-    This file is part of the AVR-Crypto-Lib.
+    This file is part of the ARM-Crypto-Lib.
     Copyright (C) 2008  Daniel Otte (daniel.otte@rub.de)
 
     This program is free software: you can redistribute it and/or modify
 =end
 
 def skip_header(file)
+  i=0
   begin
+    i += 1
     l = file.gets().strip
-  end until /[*]{10,}.*/.match(l)
-  begin
-    l = file.gets().strip
-  end until /[*]{10,}.*/.match(l)
+  end until i>10 or m=/[*]{10,}.*/.match(l)
+  if(!m)
+    file.seek(0, IO::SEEK_SET)
+  else
+    begin
+      l = file.gets().strip
+    end until /[*]{10,}.*/.match(l)
+  end
   begin
     l = file.gets().strip
   end until /[=]{5,}.*/.match(l)