aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorhiro <hiro@ee746299-78ed-0310-b773-934348b2243d>2007-04-10 05:08:16 +0000
committerhiro <hiro@ee746299-78ed-0310-b773-934348b2243d>2007-04-10 05:08:16 +0000
commit5ff17ba27424a29ae8e0ff3776944ea2a64dcab6 (patch)
tree6c451019f9a6112645fe661d56bb4c763f1bc4e1
parent460f81039d540e3eccce832b6df910d1018f3cdc (diff)
convert filename from/to UTF-8 in CSV/LDIF import.
git-svn-id: svn://sylpheed.sraoss.jp/sylpheed/trunk@1605 ee746299-78ed-0310-b773-934348b2243d
-rw-r--r--ChangeLog2
-rw-r--r--ChangeLog.ja2
-rw-r--r--src/importcsv.c8
-rw-r--r--src/importldif.c5
4 files changed, 10 insertions, 7 deletions
diff --git a/ChangeLog b/ChangeLog
index 4ebafc35..668f3d46 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,7 +1,7 @@
2007-04-10
* src/importldif.c
- src/importcsv.c: convert filename to UTF-8.
+ src/importcsv.c: convert filename from/to UTF-8.
2007-04-10
diff --git a/ChangeLog.ja b/ChangeLog.ja
index 91e6ef92..4e80f9c6 100644
--- a/ChangeLog.ja
+++ b/ChangeLog.ja
@@ -1,7 +1,7 @@
2007-04-10
* src/importldif.c
- src/importcsv.c: ファイル名を UTF-8 に変換。
+ src/importcsv.c: ファイル名を UTF-8 から/に変換。
2007-04-10
diff --git a/src/importcsv.c b/src/importcsv.c
index 78322060..6b51b5dc 100644
--- a/src/importcsv.c
+++ b/src/importcsv.c
@@ -227,9 +227,6 @@ static gboolean imp_csv_field_list_toggle( GtkCList *clist, GdkEventButton *even
return FALSE;
}
-static void imp_csv_modify_pressed( GtkWidget *widget, gpointer data ) {
-}
-
static gint imp_csv_import_data( gchar *csvFile, AddressCache *cache ) {
FILE *fp;
gchar buf[BUFFSIZE];
@@ -383,11 +380,14 @@ static gboolean imp_csv_file_move() {
}
if( ! errFlag ) {
- if ( ! imp_csv_load_fields( sFile ) ) {
+ gchar *sFSFile;
+ sFSFile = conv_filename_from_utf8( sFile );
+ if ( ! imp_csv_load_fields( sFSFile ) ) {
sMsg = _( "Error reading CSV fields." );
} else {
retVal = TRUE;
}
+ g_free( sFSFile );
}
imp_csv_status_show( sMsg );
diff --git a/src/importldif.c b/src/importldif.c
index a26501f7..01379589 100644
--- a/src/importldif.c
+++ b/src/importldif.c
@@ -329,8 +329,11 @@ static gboolean imp_ldif_file_move() {
}
if( ! errFlag ) {
+ gchar *sFSFile;
/* Read attribute list */
- ldif_set_file( _ldifFile_, sFile );
+ sFSFile = conv_filename_from_utf8( sFile );
+ ldif_set_file( _ldifFile_, sFSFile );
+ g_free( sFSFile );
if( ldif_read_tags( _ldifFile_ ) == MGU_SUCCESS ) {
/* Load fields */
/* ldif_print_file( _ldifFile_, stdout ); */