Lv.的博客

std::bad_alloc

一个服务器程序,长时间运行报错了. ----------- terminate called after throwing an instance of 'std::bad_alloc' what(): St9bad_alloc ----------- 据查为内存不足所致 new 无法分配到相应内存,内存存在泄露. std::bad_alloc is an exception that gets thrown by 'new' when it can't allocate the memory you requested. Something (very likely the standard library containers you are using) is requesting memory, and that memory can't be allocated.
posted @ 2014-12-17 09:37  Avatarx  阅读(1650)  评论(0编辑  收藏  举报