[prev in list] [next in list] [prev in thread] [next in thread]
List: linux-ntfs-cvs
Subject: [Linux-NTFS-cvs] CVS: linux-ntfs/libntfs unistr.c,1.13,1.14
From: Anton Altaparmakov <antona () users ! sourceforge ! net>
Date: 2002-04-28 21:59:14
[Download RAW message or body]
Changes by: antona
Update of /cvsroot/linux-ntfs/linux-ntfs/libntfs
In directory usw-pr-cvs1:/tmp/cvs-serv21830
Modified Files:
unistr.c
Log Message:
Cleanup.
Index: unistr.c
===================================================================
RCS file: /cvsroot/linux-ntfs/linux-ntfs/libntfs/unistr.c,v
retrieving revision 1.13
retrieving revision 1.14
diff -U2 -r1.13 -r1.14
--- unistr.c 28 Apr 2002 21:20:27 -0000 1.13
+++ unistr.c 28 Apr 2002 21:59:11 -0000 1.14
@@ -319,5 +319,5 @@
}
tc = (char*)malloc((mbs_len + 64) & ~63);
- if (!tc)
+ if (!tc)
goto err_out;
memcpy(tc, mbs, mbs_len);
@@ -332,5 +332,5 @@
/* Convert the CPU endian wide character to multibyte. */
cnt = wcrtomb(mbs + o, wc, &mbstate);
- if (cnt == (size_t)-1)
+ if (cnt == -1)
goto err_out;
if (cnt <= 0) {
@@ -395,5 +395,5 @@
Dprintf(__FUNCTION__ "(): MB_CUR_MAX = %i\n", MB_CUR_MAX);
- if (!ins || !outs) {
+ if (!ins || !outs) {
errno = EINVAL;
return -1;
@@ -427,6 +427,5 @@
tc = (uchar_t*)malloc((ucs_len + 64) & ~63);
if (!tc)
- goto err_out;
-
+ goto err_out;
memcpy(tc, ucs, ucs_len);
ucs_len = ((ucs_len + 64) & ~63) / sizeof(uchar_t);
@@ -438,9 +437,7 @@
if (!cnt)
break;
- if (cnt == -1) {
- Dprintf("cnt = %i\n",cnt);
+ if (cnt == -1)
goto err_out;
- }
- else if (cnt < -1) {
+ if (cnt < -1) {
Dprintf("Eeek. cnt = %i\n", cnt);
errno = EINVAL;
_______________________________________________
Linux-NTFS-cvs mailing list
Linux-NTFS-cvs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linux-ntfs-cvs
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic