*****************************************************************************/
static int vlclua_copyright( lua_State *L )
{
- lua_pushstring( L, COPYRIGHT_MESSAGE );
+ lua_pushliteral( L, COPYRIGHT_MESSAGE );
return 1;
}
//return luaL_error( L, "Couldn't stat %s.", psz_path );
lua_newtable( L );
if( S_ISREG( s.st_mode ) )
- lua_pushstring( L, "file" );
+ lua_pushliteral( L, "file" );
else if( S_ISDIR( s.st_mode ) )
- lua_pushstring( L, "dir" );
+ lua_pushliteral( L, "dir" );
#ifdef S_ISCHR
else if( S_ISCHR( s.st_mode ) )
- lua_pushstring( L, "character device" );
+ lua_pushliteral( L, "character device" );
#endif
#ifdef S_ISBLK
else if( S_ISBLK( s.st_mode ) )
- lua_pushstring( L, "block device" );
+ lua_pushliteral( L, "block device" );
#endif
#ifdef S_ISFIFO
else if( S_ISFIFO( s.st_mode ) )
- lua_pushstring( L, "fifo" );
+ lua_pushliteral( L, "fifo" );
#endif
#ifdef S_ISLNK
else if( S_ISLNK( s.st_mode ) )
- lua_pushstring( L, "symbolic link" );
+ lua_pushliteral( L, "symbolic link" );
#endif
#ifdef S_ISSOCK
else if( S_ISSOCK( s.st_mode ) )
- lua_pushstring( L, "socket" );
+ lua_pushliteral( L, "socket" );
#endif
else
- lua_pushstring( L, "unknown" );
+ lua_pushliteral( L, "unknown" );
lua_setfield( L, -2, "type" );
lua_pushinteger( L, s.st_mode );
lua_setfield( L, -2, "mode" );
if( luaL_newmetatable( L, "vlc_object" ) )
{
/* Hide the metatable */
- lua_pushstring( L, "none of your business" );
+ lua_pushliteral( L, "none of your business" );
lua_setfield( L, -2, "__metatable" );
if( pf_gc ) /* FIXME */
{
switch( playlist_Status( p_playlist ) )
{
case PLAYLIST_STOPPED:
- lua_pushstring( L, "stopped" );
+ lua_pushliteral( L, "stopped" );
break;
case PLAYLIST_RUNNING:
- lua_pushstring( L, "playing" );
+ lua_pushliteral( L, "playing" );
break;
case PLAYLIST_PAUSED:
- lua_pushstring( L, "paused" );
+ lua_pushliteral( L, "paused" );
break;
default:
- lua_pushstring( L, "unknown" );
+ lua_pushliteral( L, "unknown" );
break;
}
PL_UNLOCK;
*udata = p_input;
if( luaL_newmetatable( L, "input_item_t" ) )
{
- lua_pushstring( L, "none of your business" );
+ lua_pushliteral( L, "none of your business" );
lua_setfield( L, -2, "__metatable" );
}
lua_setmetatable( L, -2 );
*udata = p_input;
if( luaL_newmetatable( L, "input_item_t" ) )
{
- lua_pushstring( L, "none of your business" );
+ lua_pushliteral( L, "none of your business" );
lua_setfield( L, -2, "__metatable" );
}
lua_setmetatable( L, -2 );
}
else
{
- lua_pushstring( L, "" );
+ lua_pushliteral( L, "" );
}
return vlclua_push_ret( L, ret ) + 1;
}