# \[68982 Closed\] "Out of memory" exception raised in TROIndyTCPServer

**URL:** https://talk.remobjects.com/t/68982-closed-out-of-memory-exception-raised-in-troindytcpserver/4693
**Category:** Remoting SDK
**Created:** [July 31, 2014, 8:49am UTC](https://talk.remobjects.com/t/68982-closed-out-of-memory-exception-raised-in-troindytcpserver/4693 "2014-07-31T08:49:06Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![impet](https://talk.remobjects.com/letter_avatar_proxy/v4/letter/i/7993a0/32.png) [@impet](https://talk.remobjects.com/u/impet)
#### Post date: [July 31, 2014, 8:49am UTC](https://talk.remobjects.com/t/68982-closed-out-of-memory-exception-raised-in-troindytcpserver/4693/1 "2014-07-31T08:49:07Z")

</div>

“Out of memory” exception raised in TROIndyTCPServer in case access from WebBrowser.

Steps to reproduce:

1. Run MegaDemoServer under Delphi IDE
2. Activate Indy TCP Server
3. In WebBrowser go to localhost:8090
4. Exception “Out of memory” raised in server

---

<div class="post-metadata">

### Author: ![EvgenyK](https://talk.remobjects.com/user_avatar/talk.remobjects.com/evgenyk/32/16_2.png) [@EvgenyK](https://talk.remobjects.com/u/EvgenyK)
#### Post date: [July 31, 2014, 10:02am UTC](https://talk.remobjects.com/t/68982-closed-out-of-memory-exception-raised-in-troindytcpserver/4693/2 "2014-07-31T10:02:46Z")

</div>

pls specify what version of delphi and ROD you are using.

I’ve got only

```auto
---------------------------
Debugger Exception Notification
---------------------------
Project MegaDemoServer.exe raised exception class EIdSocketError with message 'Socket Error # 10054
Connection reset by peer.'.
---------------------------
Break   Continue   Help   
---------------------------

```

---

<div class="post-metadata">

### Author: ![impet](https://talk.remobjects.com/letter_avatar_proxy/v4/letter/i/7993a0/32.png) [@impet](https://talk.remobjects.com/u/impet)
#### Post date: [August 1, 2014, 6:12am UTC](https://talk.remobjects.com/t/68982-closed-out-of-memory-exception-raised-in-troindytcpserver/4693/3 "2014-08-01T06:12:27Z")

</div>

Delphi XE5 update 2 + RemObjects SDK 8.0.83.1137.

This is a call stack:  
:74d31d4d KERNELBASE.RaiseException + 0x48  
System.Classes.TMemoryStream.Realloc(4975750)  
:004bec86 TMemoryStream.Realloc + $4E  
System.Classes.TMemoryStream.Realloc(???)  
System.Classes.TMemoryStream.SetCapacity(80739860)  
System.Classes.TMemoryStream.SetSize(???)  
System.Classes.TStream.SetSize(1195725856)  
System.Classes.TStream.SetSize64(1195725856)  
IdIOHandler.AdjustStreamSize($8F5E60,1195725856)  
IdIOHandler.TIdIOHandler.ReadStream($8F5E60,-1,False)  
uROIndyTCPServer.TROCustomIndyTCPServer.InternalOnExecute($92CB10)  
IdCustomTCPServer.TIdCustomTCPServer.DoExecute($92CB10)  
IdContext.TIdContext.Run  
IdTask.TIdTask.DoRun  
IdThread.TIdThreadWithTask.Run  
IdThread.TIdThread.Execute  
System.Classes.ThreadProc($8A2990)  
System.ThreadWrapper($9018D0)  
:7521919f KERNEL32.BaseThreadInitThunk + 0xe  
:771da22b ntdll.RtlInitializeExceptionChain + 0x84  
:771da201 ntdll.RtlInitializeExceptionChain + 0x5a

---

<div class="post-metadata">

### Author: ![RemObjectsSoftware](https://talk.remobjects.com/user_avatar/talk.remobjects.com/remobjectssoftware/32/15947_2.png) [@RemObjectsSoftware](https://talk.remobjects.com/u/RemObjectsSoftware)
#### Post date: [August 6, 2014, 12:04pm UTC](https://talk.remobjects.com/t/68982-closed-out-of-memory-exception-raised-in-troindytcpserver/4693/4 "2014-08-06T12:04:56Z")

</div>

Thanks, logged as bugs://68982: “Out of memory” exception raised in TROIndyTCPServer

---

<div class="post-metadata">

### Author: ![EvgenyK](https://talk.remobjects.com/user_avatar/talk.remobjects.com/evgenyk/32/16_2.png) [@EvgenyK](https://talk.remobjects.com/u/EvgenyK)
#### Post date: [August 6, 2014, 12:07pm UTC](https://talk.remobjects.com/t/68982-closed-out-of-memory-exception-raised-in-troindytcpserver/4693/5 "2014-08-06T12:07:32Z")

</div>

I still think, that it is a bug in Indy because indy thinks that buffer with data is present and buffer has size = random integer …

---

<div class="post-metadata">

### Author: ![RemObjectsSoftware](https://talk.remobjects.com/user_avatar/talk.remobjects.com/remobjectssoftware/32/15947_2.png) [@RemObjectsSoftware](https://talk.remobjects.com/u/RemObjectsSoftware)
#### Post date: [October 27, 2014, 11:18am UTC](https://talk.remobjects.com/t/68982-closed-out-of-memory-exception-raised-in-troindytcpserver/4693/6 "2014-10-27T11:18:18Z")

</div>

bugs://68982 got closed as fixed for release DA8.2
