3434#include <string.h>
3535
3636#include "lib/global.h"
37- #include "lib/strutil.h" /* utf-8 functions */
37+ #include "lib/strutil.h" // utf-8 functions
3838#include "lib/fileloc.h"
39- #include "lib/util.h" /* whitespace() */
39+ #include "lib/util.h" // whitespace()
4040
4141#include "lib/charsets.h"
4242
@@ -106,7 +106,7 @@ load_codepages_list_from_file (GPtrArray **list, const char *fname)
106106
107107 while (fgets (buf , sizeof buf , f ) != NULL )
108108 {
109- /* split string into id and cpname */
109+ // split string into id and cpname
110110 char * p = buf ;
111111 size_t buflen ;
112112
@@ -142,8 +142,8 @@ load_codepages_list_from_file (GPtrArray **list, const char *fname)
142142 {
143143 unsigned int i ;
144144
145- /* whether id is already present in list */
146- /* if yes, overwrite description */
145+ // whether id is already present in list
146+ // if yes, overwrite description
147147 for (i = 0 ; i < (* list )-> len ; i ++ )
148148 {
149149 codepage_desc * desc ;
@@ -152,14 +152,14 @@ load_codepages_list_from_file (GPtrArray **list, const char *fname)
152152
153153 if (strcmp (id , desc -> id ) == 0 )
154154 {
155- /* found */
155+ // found
156156 g_free (desc -> name );
157157 desc -> name = g_strdup (p );
158158 break ;
159159 }
160160 }
161161
162- /* not found */
162+ // not found
163163 if (i == (* list )-> len )
164164 g_ptr_array_add (* list , new_codepage_desc (id , p ));
165165 }
@@ -203,19 +203,19 @@ load_codepages_list (void)
203203{
204204 char * fname ;
205205
206- /* 1: try load /usr/share/mc/mc.charsets */
206+ // 1: try load /usr/share/mc/mc.charsets
207207 fname = g_build_filename (mc_global .share_data_dir , CHARSETS_LIST , (char * ) NULL );
208208 load_codepages_list_from_file (& codepages , fname );
209209 g_free (fname );
210210
211- /* 2: try load /etc/mc/mc.charsets */
211+ // 2: try load /etc/mc/mc.charsets
212212 fname = g_build_filename (mc_global .sysconfig_dir , CHARSETS_LIST , (char * ) NULL );
213213 load_codepages_list_from_file (& codepages , fname );
214214 g_free (fname );
215215
216216 if (codepages == NULL )
217217 {
218- /* files are not found, add default codepage */
218+ // files are not found, add default codepage
219219 fprintf (stderr , "%s\n" , _ ("Warning: cannot load codepages list" ));
220220
221221 codepages = g_ptr_array_new_with_free_func (free_codepage_desc );
229229free_codepages_list (void )
230230{
231231 g_ptr_array_free (codepages , TRUE);
232- /* NULL-ize pointer to make unit tests happy */
232+ // NULL-ize pointer to make unit tests happy
233233 codepages = NULL ;
234234}
235235
@@ -288,7 +288,7 @@ init_translation_table (int cpsource, int cpdisplay)
288288 int i ;
289289 GIConv cd ;
290290
291- /* Fill input <-> display tables */
291+ // Fill input <-> display tables
292292
293293 if (cpsource < 0 || cpdisplay < 0 || cpsource == cpdisplay )
294294 {
@@ -309,7 +309,7 @@ init_translation_table (int cpsource, int cpdisplay)
309309 cp_source = ((codepage_desc * ) g_ptr_array_index (codepages , cpsource ))-> id ;
310310 cp_display = ((codepage_desc * ) g_ptr_array_index (codepages , cpdisplay ))-> id ;
311311
312- /* display <- inpit table */
312+ // display <- inpit table
313313
314314 cd = g_iconv_open (cp_display , cp_source );
315315 if (cd == INVALID_CONV )
@@ -320,7 +320,7 @@ init_translation_table (int cpsource, int cpdisplay)
320320
321321 g_iconv_close (cd );
322322
323- /* inpit <- display table */
323+ // inpit <- display table
324324
325325 cd = g_iconv_open (cp_source , cp_display );
326326 if (cd == INVALID_CONV )
0 commit comments