AC_MSG_ERROR("The gtk client cannot be built without nls support. Try adding either --enable-nls or --disable-gtk" )
fi
+dnl This section is only used for internationalization.
+dnl If you don't need translations and this section gives you trouble --
+dnl such as if you're building for a headless system --
+dnl it's okay to tear this section out and re-build the configure script.
use_nls=no
if test "x$enable_nls" = "xyes" ; then
use_nls=yes
{
guint tag;
int row;
- char *s;
+ const char *s;
GSList *group;
GtkWidget *t, *w, *tb, *h;
g_thread_init( NULL );
gerr = NULL;
- if( !gtk_init_with_args( &argc, &argv, _( "[torrent files]" ), entries,
+ if( !gtk_init_with_args( &argc, &argv, (char*)_( "[torrent files]" ), entries,
(char*)domain, &gerr ) )
{
fprintf( stderr, "%s\n", gerr->message );
G_TYPE_UINT, cookie,
G_TYPE_INVALID );
if( success )
- tr_inf( _( "Disallowing desktop hibernation" ) );
+ tr_inf( "%s", _( "Disallowing desktop hibernation" ) );
else
{
- tr_err( _(
- "Couldn't disable desktop hibernation: %s" ),
+ tr_err( _( "Couldn't disable desktop hibernation: %s" ),
error->message );
g_error_free( error );
}
G_TYPE_INVALID,
G_TYPE_INVALID );
if( success )
- tr_inf( _( "Allowing desktop hibernation" ) );
+ tr_inf( "%s", _( "Allowing desktop hibernation" ) );
else
{
g_warning( "Couldn't uninhibit the system from suspending: %s.",
GTK_DIALOG_DESTROY_WITH_PARENT,
GTK_MESSAGE_INFO,
GTK_BUTTONS_CLOSE,
- _( "Update Blocklist" ) );
+ "%s", _( "Update Blocklist" ) );
gtk_widget_set_sensitive( data->updateBlocklistButton, FALSE );
- gtk_message_dialog_format_secondary_text( GTK_MESSAGE_DIALOG( d ), _( "Getting new blocklist..." ) );
+ gtk_message_dialog_format_secondary_text( GTK_MESSAGE_DIALOG( d ), "%s", _( "Getting new blocklist..." ) );
data->updateBlocklistDialog = d;
g_signal_connect( d, "response", G_CALLBACK(onBlocklistUpdateResponse), data );
gtk_widget_show( d );
GTK_DIALOG_DESTROY_WITH_PARENT,
GTK_MESSAGE_ERROR,
GTK_BUTTONS_CLOSE,
- _( "Error opening torrent" ) );
+ "%s", _( "Error opening torrent" ) );
gtk_message_dialog_format_secondary_text( GTK_MESSAGE_DIALOG( w ),
"%s", secondary );
g_signal_connect_swapped( w, "response",
default:
/* did caller give us an uninitialized val? */
- tr_err( _( "Invalid metadata" ) );
+ tr_err( "%s", _( "Invalid metadata" ) );
break;
}
}
if( !buf )
/* %s is the torrent name */
- tr_torinf( tor, _( "Couldn't read resume file" ) );
+ tr_torinf( tor, "%s", _( "Couldn't read resume file" ) );
else
{
const uint8_t * walk = buf;
ret |= parseVersion1 ( tor, walk, end, fieldsToLoad );
else
/* %s is the torrent name */
- tr_torinf( tor, _( "Couldn't read resume file" ) );
+ tr_torinf( tor, "%s", _( "Couldn't read resume file" ) );
}
tr_free( buf );
static void
stop_forwarding( tr_shared * s )
{
- tr_ninf( getKey( ), _( "Stopped" ) );
+ tr_ninf( getKey( ), "%s", _( "Stopped" ) );
natPulse( s, FALSE );
tr_natpmpClose( s->natpmp );
s->natpmp = NULL;
tr_runInEventThread( session, startServer, s );
if( s->isWhitelistEnabled )
- tr_ninf( MY_NAME, _( "Whitelist enabled" ) );
+ tr_ninf( MY_NAME, "%s", _( "Whitelist enabled" ) );
if( s->isPasswordEnabled )
- tr_ninf( MY_NAME, _( "Password required" ) );
+ tr_ninf( MY_NAME, "%s", _( "Password required" ) );
}
return s;
handle->lanaddr, port );
if( handle->isMapped )
{
- tr_ninf( getKey( ), _( "Port forwarding successful!" ) );
+ tr_ninf( getKey( ), "%s", _( "Port forwarding successful!" ) );
handle->port = port;
handle->state = TR_UPNP_IDLE;
}
tr_free( node );
tr_lockUnlock( getVerifyLock( ) );
- tr_torinf( tor, _( "Verifying torrent" ) );
+ tr_torinf( tor, "%s", _( "Verifying torrent" ) );
tr_torrentSetVerifyState( tor, TR_VERIFY_NOW );
changed = verifyTorrent( tor, &stopCurrent );
tr_torrentSetVerifyState( tor, TR_VERIFY_NONE );
{
struct verify_node * node;
- tr_torinf( tor, _( "Queued for verification" ) );
+ tr_torinf( tor, "%s", _( "Queued for verification" ) );
node = tr_new( struct verify_node, 1 );
node->torrent = tor;