lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


> I added the following line just before the pushlstring in question:
> 
> printf("name = %s (len %d) len = %d\n", iev->name, strlen(iev->name),
> iev->len);
> 
> And lo and behold, what output do I get?  
> This:
> 
> name = foo (len 3) len = 16
> 
> Looks like I need to look at the inotify docs again...

I did the same just now.  man inotify says:
	char     name[];   /* Optional null-terminated name */

So, the solution is to use simply
	lua_pushstring(L,iev->name)