> I have found some problems with the file chooser on AIX and NetBSD > operating systems and opened STR #2935 with a patch to fix them: > Selecting "File systems" from the menu shows either nothing (not even > the root filesystem on AIX) or many entries that make no sense or are > not available (like swap partitions on NetBSD). > > The problem is that the method 'Fl_File_Browser::load()' can't > determine > the mount points correctly. Unfortunately there seems to be no portable > way to get this information, therefore I have added special handling > code inside '#ifdef' for both cases. > Up to here the first part should not affect other operating systems at > all. > > In addition the patch adds a general default section to show at least > the root filesystems if all other options have failed (and show the > root > filesystem consistenly as "/" on all Unix systems). > This second part may affect other operating systems but is completely > independent from the first part. > > Is this patch acceptable?
Hi Micha, The patch looks OK for the most part, though I have a few small comments; note also I have neither a AIX nor BSD system to actually test on, so this is just inspections really! - The code doesn't seem to quite match the supposed fltk coding style, see: http://www.fltk.org/cmp.php#CS_GENERAL_CODING_STYLE for more guidelines. (I confess this is often an issue for me, the fltk style is not my default style...) - Is there a possibility that the AIX branch can call "free((void *) list);" even if list has not been malloc'd? Would it be bad if it did? - This is a nit-pick of mine, but I prefer: if (strcmp("/", filename) != 0) instead of if (strcmp("/", filename)) simply because it reminds me that strcmp returns 0 for a match... I doubt most people care about that though! Cheers, -- Ian Selex ES Ltd Registered Office: Sigma House, Christopher Martin Road, Basildon, Essex SS14 3EL A company registered in England & Wales. Company no. 02426132 ******************************************************************** This email and any attachments are confidential to the intended recipient and may also be privileged. If you are not the intended recipient please delete it from your system and notify the sender. You should not copy it or use it for any purpose nor disclose or distribute its contents to any other person. ******************************************************************** _______________________________________________ fltk mailing list fltk@easysw.com http://lists.easysw.com/mailman/listinfo/fltk