IMesh:BuildFromTriangles() ends up crashing my game

so i’ve been trying to make a collision mesh and i need to visualize it when i’m adding each triangle. then, as soon as BuildFromTriangles gets called, it crashes my game with this error

i’ve googled the error and it has something to do with not enough paged pool memory available for gmod. i don’t understand how this could be the case though, as other addons that utilize BuildFromTriangles don’t crash my game at all.
here’s the code that i used
[lua]
local mat = Material( “editor/wireframe” ) – The material ( a wireframe )
local obj = Mesh( mat ) – Create the IMesh object

local origin = Vector( 2642, 2660, -5375 )
local ang = Angle( 0, 0, 0 )

local verts = {
{pos = Vector( -25, 0, 0 ),},
{pos = Vector( -25, 0, 25 ),},
{pos = Vector( 25, 0, 0 ),},

{pos = Vector( 25, 0, 25 ),},
{pos = Vector( 25, 0, 0 )},
{pos = Vector( -25, 0, 25 )},

{ pos = Vector( -25, 0, 25 ) },
{ pos = Vector( -25, 0, 19 ) },
{ pos = Vector( -45, 0, 22 ) },

{ pos = Vector( -45, 0, 32 ) },
{ pos = Vector( -25, 0, 25 ) },
{ pos = Vector( -45, 0, 22 ) },

{ pos = Vector( 25, 0, 19 ) },
{ pos = Vector( 25, 0, 25 ) },
{ pos = Vector( 45, 0, 22 ) },

{ pos = Vector( 45, 0, 32 ) },
{ pos = Vector( 45, 0, 22 ) },
{ pos = Vector( 25, 0, 25 ) },

}
for k,v in pairs( verts ) do
v.pos = LocalToWorld( v.pos, Angle( 0, 0, 0 ), origin, ang )
end
obj:BuildFromTriangles( verts )
hook.Add( “PostDrawOpaqueRenderables”, “IMesh”, function()
render.SetMaterial( mat ) – Apply the material
obj:Draw() – Draw the mesh
end )
[/lua]
any help would be appreciated

Where is this chunk of code running?

on my client

[editline]8/1/2015[/editline]
found the problem! LocalToWorld returns two arguments but i was assigning them to one variable