patch-mount_mount_c 708 B

12345678910111213141516
  1. --- util-linux-ng-2.15.orig/mount/mount.c 2009-03-27 13:13:20.000000000 +0100
  2. +++ util-linux-ng-2.15/mount/mount.c 2009-06-22 22:58:48.000000000 +0200
  3. @@ -914,11 +914,11 @@ guess_fstype_and_mount(const char *spec,
  4. /* Accept a comma-separated list of types, and try them one by one */
  5. /* A list like "nonfs,.." indicates types not to use */
  6. - if (*types && strncmp(*types, "no", 2) && index(*types,',')) {
  7. + if (*types && strncmp(*types, "no", 2) && strchr(*types,',')) {
  8. char *t = strdup(*types);
  9. char *p;
  10. - while((p = index(t,',')) != NULL) {
  11. + while((p = strchr(t,',')) != NULL) {
  12. *p = 0;
  13. args.type = *types = t;
  14. if (do_mount (&args, special, status) == 0)