H
huanq
Unregistered / Unconfirmed
GUEST, unregistred user!
有一段程序
for i:=0 to serversocket1.Socket.ActiveConnections-1 do
begin
if i=0 then
begin
b:=tmemorystream.Create;
b.Write(a,sizeof(a));
end;
b.Position:=0;
try
serversocket1.Socket.Connections.Sendstream(b);
except
break;
end;
if i=(serversocket1.Socket.ActiveConnections-1) then
begin
b.Position:=0;
b.Clear;
// b.free;
end;}
end;
(a 为我要传送的数组)
可每次执行到
b.clear;
都出现错误 Access violation at address ......
换成
b.free;
也不行
请各位大虾指点一二,多谢!