Show
Ignore:
Timestamp:
09/02/11 04:38:29 (3 years ago)
Author:
Theo Schlossnagle <jesus@omniti.com>
git-committer:
Theo Schlossnagle <jesus@omniti.com> 1314938309 -0400
git-parent:

[191ce1d37e96ab06d4218f01a6c813946fdd6d82]

git-author:
Theo Schlossnagle <jesus@omniti.com> 1314938309 -0400
Message:

pushing nil on and calling with three args was causing an issue

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • src/modules/lua.c

    re437d46 r55a550b  
    681681          err = lua_tostring(ci->coro_state, base); 
    682682          nerr = lua_tostring(ci->coro_state, base - 2); 
     683          if(err) noitL(nldeb, "err -> %s\n", err); 
     684          if(nerr) noitL(nldeb, "nerr -> %s\n", nerr); 
    683685          if(nerr && *nerr == 31) nerr = NULL; // 31? WTF lua? 
    684686          if(!nerr && err) { 
     
    788790  noit_lua_setup_module(ci->coro_state, ci->self); 
    789791  noit_lua_setup_check(ci->coro_state, ci->check); 
    790   if(cause) noit_lua_setup_check(ci->coro_state, ci->cause); 
    791   else lua_pushnil(L); 
    792   noit_lua_resume(ci, 3); 
    793  
     792  if(cause) { 
     793    noit_lua_setup_check(ci->coro_state, ci->cause); 
     794    noit_lua_resume(ci, 3); 
     795  } 
     796  else 
     797    noit_lua_resume(ci, 2); 
    794798  return 0; 
    795799