Index: /issm/trunk-jpl/src/m/exp/expread.m
===================================================================
--- /issm/trunk-jpl/src/m/exp/expread.m	(revision 13337)
+++ /issm/trunk-jpl/src/m/exp/expread.m	(revision 13338)
@@ -46,5 +46,5 @@
 	%Get Icon
 	A=fscanf(fid,'%s %s',2);
-	if ~strncmp(A,'##Icon:',6), break; end
+	if ~strncmp(A,'##Icon:',7), break; end
 
 	%Get Info
Index: /issm/trunk-jpl/src/m/exp/expread.py
===================================================================
--- /issm/trunk-jpl/src/m/exp/expread.py	(revision 13337)
+++ /issm/trunk-jpl/src/m/exp/expread.py	(revision 13338)
@@ -1,4 +1,5 @@
 import os.path
 import numpy
+from collections import OrderedDict
 from MatlabFuncs import *
 
@@ -38,15 +39,17 @@
 
 		#update number of profiles
-		Struct={}
+		Struct=OrderedDict()
 
 		#Get file name
-		A=fid.readline().split(None,1)
+		A=fid.readline()
+		while A=='\n':
+			A=fid.readline()
 		if not A:
 			break
-		A=A[0]+A[1]
-		if not strncmp(A,'##Name:',7):
+		A=A.split(None,1)
+		if not (len(A) == 2 and strcmp(A[0],'##') and strncmp(A[1],'Name:',5)):
 			break
-		if len(A)>7: 
-			Struct['name']=A[7:-1]
+		if len(A[1])>5: 
+			Struct['name']=A[1][5:-1]
 		else:
 			Struct['name']=''
@@ -54,12 +57,10 @@
 		#Get Icon
 		A=fid.readline().split(None,1)
-		A=A[0]+A[1]
-		if not strncmp(A,'##Icon:',6):
+		if not (len(A) == 2 and strcmp(A[0],'##') and strncmp(A[1],'Icon:',5)):
 			break
 
 		#Get Info
-		A=fid.readline().split(None,3)
-		A=A[0]+A[1]+A[2]+A[3]
-		if not strncmp(A,'#Points',7):
+		A=fid.readline().split()
+		if not (len(A) == 4 and strcmp(A[0],'#') and strcmp(A[1],'Points')):
 			break
 
@@ -70,7 +71,7 @@
 
 		#Get Info
-		A=fid.readline().split(None,4)
-		A=A[0]+A[1]+A[2]+A[3]+A[4]
-		if not strncmp(A,'#XposYpos',9):
+		A=fid.readline().split()
+		if not (len(A) == 5 and strcmp(A[0],'#') and strcmp(A[1],'X') and strcmp(A[2],'pos') \
+		                                         and strcmp(A[3],'Y') and strcmp(A[4],'pos')):
 			break
 
