- faq.html:
- Fix typos and small mistakes (Jordi).
- files.c:
+ username_tab_completion()
+ - Added the (char *) sizeof when allocating memory for the filename
+ array (Rocco).
cwd_tab_completion()
- removed skipping . and .. when tabulating matches.
+ - Added the (char *) sizeof when allocating memory for the filename
+ array (Rocco).
- nano.c:
main()
- Reorder the getopt options to be more or less alphabetical
homedirs = (char **) NULL;
*num_matches = 0;
}
- matches = nmalloc(BUFSIZ);
- homedirs = nmalloc(BUFSIZ);
+ matches = nmalloc(BUFSIZ * sizeof(char *));
+ homedirs = nmalloc(BUFSIZ * sizeof(char *));
strcat(buf, "*");
do {
i = 0;
DIR *dir;
struct dirent *next;
- matches = nmalloc(BUFSIZ);
+ matches = nmalloc(BUFSIZ * sizeof(char *));
/* Stick a wildcard onto the buf, for later use */
strcat(buf, "*");