patch-2.2.6 linux/fs/ntfs/support.c

Next file: linux/fs/open.c
Previous file: linux/fs/ntfs/super.h
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.2.5/linux/fs/ntfs/support.c linux/fs/ntfs/support.c
@@ -246,6 +246,10 @@
 		if(!(vol->nct & nct_uni_xlate))goto inval;
 		/* realloc */
 		buf=ntfs_malloc(*out_len+3);
+		if( !buf ) {
+			ntfs_free( result );
+			return ENOMEM;
+		}
 		memcpy(buf,result,o);
 		ntfs_free(result);
 		result=buf;

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)