diff options
author | Alexey Kulakov <panda75@bk.ru> | 2014-12-31 17:08:47 +0000 |
---|---|---|
committer | Alexey Kulakov <panda75@bk.ru> | 2014-12-31 17:08:47 +0000 |
commit | da87b3fa0479333cfe9505713f6ffaa54b9ba543 (patch) | |
tree | d4868e4947c3944bb3313a057ec3b189a876018f /plugins/Watrack/formats/fmt_real.pas | |
parent | f33f9ebac9806cba6bfd89715566a65c29b5fee2 (diff) |
pascal code: reformat, small fixes
git-svn-id: http://svn.miranda-ng.org/main/trunk@11700 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Watrack/formats/fmt_real.pas')
-rw-r--r-- | plugins/Watrack/formats/fmt_real.pas | 40 |
1 files changed, 20 insertions, 20 deletions
diff --git a/plugins/Watrack/formats/fmt_real.pas b/plugins/Watrack/formats/fmt_real.pas index 8d5f5bf72d..1d69a2f353 100644 --- a/plugins/Watrack/formats/fmt_real.pas +++ b/plugins/Watrack/formats/fmt_real.pas @@ -23,7 +23,7 @@ const type
tChunk = packed record
ID:dword;
- Len:dword; //with Chunk;
+ len:dword; //with Chunk;
end;
type
@@ -43,32 +43,32 @@ type procedure SkipStr(var p:PAnsiChar;alen:integer);
var
- len:integer;
+ llen:integer;
begin
if alen=2 then
- len:=(ord(p[0]) shl 8)+ord(p[1])
+ llen:=(ord(p[0]) shl 8)+ord(p[1])
else
- len:=ord(p[0]);
+ llen:=ord(p[0]);
inc(p,alen);
-// if len>0 then
- inc(p,len);
+// if llen>0 then
+ inc(p,llen);
end;
function ReadStr(var p:PAnsiChar;alen:integer):PAnsiChar;
var
- len:integer;
+ llen:integer;
begin
if alen=2 then
- len:=(ord(p[0]) shl 8)+ord(p[1])
+ llen:=(ord(p[0]) shl 8)+ord(p[1])
else
- len:=ord(p[0]);
+ llen:=ord(p[0]);
inc(p,alen);
- if len>0 then
+ if llen>0 then
begin
- mGetMem(result,len+1);
- move(p^,result^,len);
- result[len]:=#0;
- inc(p,len);
+ mGetMem(result,llen+1);
+ move(p^,result^,llen);
+ result[llen]:=#0;
+ inc(p,llen);
end
else
result:=nil;
@@ -103,15 +103,15 @@ begin while FilePos(f)<fsize do
begin
BlockRead(f,chunk,SizeOf(chunk));
- chunk.Len:=BSwap(chunk.Len);
+ chunk.len:=BSwap(chunk.len);
if (not (AnsiChar(chunk.ID and $FF) in ['A'..'Z','a'..'z','.'])) or
- (chunk.Len<SizeOf(chunk)) then
+ (chunk.len<SizeOf(chunk)) then
break;
if (chunk.ID=blkPROP) or (chunk.ID=blkCONT) or (chunk.ID=blkMDPR) then
begin
- mGetMem(buf,chunk.Len-SizeOf(chunk));
+ mGetMem(buf,chunk.len-SizeOf(chunk));
p:=buf;
- BlockRead(f,buf^,chunk.Len-SizeOf(chunk));
+ BlockRead(f,buf^,chunk.len-SizeOf(chunk));
if chunk.ID=blkPROP then
begin
inc(p,22);
@@ -273,7 +273,7 @@ begin end
else if chunk.ID=blkRMMD then //comment
begin
- Skip(f,chunk.Len-SizeOf(chunk));
+ Skip(f,chunk.len-SizeOf(chunk));
{
BlockRead(f,chunk,SizeOf(chunk)); //RJMD
chunk.len:=BSwap(chunk.len);
@@ -289,7 +289,7 @@ begin if chunk.ID=blk_RMF then
if FilePos(f)<>SizeOf(chunk) then // channels-1: ofs=$0A
break;
- Skip(f,chunk.Len-SizeOf(chunk));
+ Skip(f,chunk.len-SizeOf(chunk));
end;
end;
ReadID3v1(f,Info);
|