You can subscribe to this list here.
| 2007 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(2) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2008 |
Jan
(7) |
Feb
(2) |
Mar
(32) |
Apr
(25) |
May
(11) |
Jun
(25) |
Jul
(5) |
Aug
(8) |
Sep
|
Oct
(8) |
Nov
(13) |
Dec
(17) |
| 2009 |
Jan
(34) |
Feb
(18) |
Mar
(4) |
Apr
|
May
(9) |
Jun
(1) |
Jul
(9) |
Aug
|
Sep
(12) |
Oct
|
Nov
(9) |
Dec
(1) |
| 2010 |
Jan
(1) |
Feb
(14) |
Mar
|
Apr
|
May
(4) |
Jun
(14) |
Jul
(4) |
Aug
|
Sep
|
Oct
|
Nov
(4) |
Dec
(225) |
| 2011 |
Jan
(17) |
Feb
|
Mar
|
Apr
(27) |
May
(24) |
Jun
(1) |
Jul
(3) |
Aug
(22) |
Sep
(24) |
Oct
(22) |
Nov
(6) |
Dec
(4) |
| 2012 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(6) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2013 |
Jan
|
Feb
|
Mar
(2) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(2) |
Oct
|
Nov
|
Dec
|
| 2014 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(4) |
Jun
|
Jul
(1) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2015 |
Jan
|
Feb
(1) |
Mar
|
Apr
(8) |
May
(21) |
Jun
|
Jul
(2) |
Aug
|
Sep
(1) |
Oct
|
Nov
|
Dec
|
| 2016 |
Jan
|
Feb
|
Mar
(1) |
Apr
|
May
|
Jun
|
Jul
|
Aug
(1) |
Sep
(1) |
Oct
|
Nov
|
Dec
(1) |
| 2017 |
Jan
|
Feb
|
Mar
|
Apr
(2) |
May
|
Jun
|
Jul
|
Aug
|
Sep
(1) |
Oct
|
Nov
|
Dec
|
| 2018 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(1) |
Dec
(27) |
| 2019 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(5) |
Aug
(7) |
Sep
(16) |
Oct
(3) |
Nov
|
Dec
|
|
From: <lab...@us...> - 2019-10-03 23:18:00
|
Revision: 1615
http://sourceforge.net/p/opengtoolkit/svn/1615
Author: labviewer
Date: 2019-10-03 23:17:58 +0000 (Thu, 03 Oct 2019)
Log Message:
-----------
Add parsing of extra field info data to retrieve unix timestamp information
Modified Paths:
--------------
trunk/lvzip/source/lvzip.llb/ZLIB File Information.vi
trunk/lvzip/source/lvzip.llb/ZLIB Store File.vi
trunk/lvzip/source/lvzip.llb/ZLIB Store Link.vi
trunk/lvzip/source/lvzip.llb/ZLIB VI Tree.vi
Added Paths:
-----------
trunk/lvzip/source/lvzip.llb/ZLIB Extract Extra Fields.vi
trunk/lvzip/source/lvzip.llb/ZLIB Parse Extra Field Data.vi
trunk/lvzip/source/lvzip.llb/ZLIB Read Locale Extra Info.vi
trunk/lvzip/source/lvzip.llb/ZLIB Update File Attributes.vi
Added: trunk/lvzip/source/lvzip.llb/ZLIB Extract Extra Fields.vi
===================================================================
(Binary files differ)
Index: trunk/lvzip/source/lvzip.llb/ZLIB Extract Extra Fields.vi
===================================================================
--- trunk/lvzip/source/lvzip.llb/ZLIB Extract Extra Fields.vi 2019-10-03 23:15:14 UTC (rev 1614)
+++ trunk/lvzip/source/lvzip.llb/ZLIB Extract Extra Fields.vi 2019-10-03 23:17:58 UTC (rev 1615)
Property changes on: trunk/lvzip/source/lvzip.llb/ZLIB Extract Extra Fields.vi
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Modified: trunk/lvzip/source/lvzip.llb/ZLIB File Information.vi
===================================================================
(Binary files differ)
Added: trunk/lvzip/source/lvzip.llb/ZLIB Parse Extra Field Data.vi
===================================================================
(Binary files differ)
Index: trunk/lvzip/source/lvzip.llb/ZLIB Parse Extra Field Data.vi
===================================================================
--- trunk/lvzip/source/lvzip.llb/ZLIB Parse Extra Field Data.vi 2019-10-03 23:15:14 UTC (rev 1614)
+++ trunk/lvzip/source/lvzip.llb/ZLIB Parse Extra Field Data.vi 2019-10-03 23:17:58 UTC (rev 1615)
Property changes on: trunk/lvzip/source/lvzip.llb/ZLIB Parse Extra Field Data.vi
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Added: trunk/lvzip/source/lvzip.llb/ZLIB Read Locale Extra Info.vi
===================================================================
(Binary files differ)
Index: trunk/lvzip/source/lvzip.llb/ZLIB Read Locale Extra Info.vi
===================================================================
--- trunk/lvzip/source/lvzip.llb/ZLIB Read Locale Extra Info.vi 2019-10-03 23:15:14 UTC (rev 1614)
+++ trunk/lvzip/source/lvzip.llb/ZLIB Read Locale Extra Info.vi 2019-10-03 23:17:58 UTC (rev 1615)
Property changes on: trunk/lvzip/source/lvzip.llb/ZLIB Read Locale Extra Info.vi
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Store File.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Store Link.vi
===================================================================
(Binary files differ)
Added: trunk/lvzip/source/lvzip.llb/ZLIB Update File Attributes.vi
===================================================================
(Binary files differ)
Index: trunk/lvzip/source/lvzip.llb/ZLIB Update File Attributes.vi
===================================================================
--- trunk/lvzip/source/lvzip.llb/ZLIB Update File Attributes.vi 2019-10-03 23:15:14 UTC (rev 1614)
+++ trunk/lvzip/source/lvzip.llb/ZLIB Update File Attributes.vi 2019-10-03 23:17:58 UTC (rev 1615)
Property changes on: trunk/lvzip/source/lvzip.llb/ZLIB Update File Attributes.vi
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Modified: trunk/lvzip/source/lvzip.llb/ZLIB VI Tree.vi
===================================================================
(Binary files differ)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <lab...@us...> - 2019-10-03 23:15:15
|
Revision: 1614
http://sourceforge.net/p/opengtoolkit/svn/1614
Author: labviewer
Date: 2019-10-03 23:15:14 +0000 (Thu, 03 Oct 2019)
Log Message:
-----------
Make file utility functions work and add string variants in order to support UTF8 file names
Modified Paths:
--------------
trunk/lvzip/source/lvzlib.dll
trunk/lvzip/source/lvzlib.so
trunk/lvzip/source/lvzlib64.dll
trunk/lvzip/source/lvzlib64.so
Modified: trunk/lvzip/source/lvzlib.dll
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzlib.so
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzlib64.dll
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzlib64.so
===================================================================
(Binary files differ)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <lab...@us...> - 2019-10-03 23:12:41
|
Revision: 1613
http://sourceforge.net/p/opengtoolkit/svn/1613
Author: labviewer
Date: 2019-10-03 23:12:40 +0000 (Thu, 03 Oct 2019)
Log Message:
-----------
Make file utility functions work and add string variants in order to support UTF8 file names
Modified Paths:
--------------
trunk/lvzip/source/fileutil.llb/FILE Attributes.ctl
trunk/lvzip/source/fileutil.llb/FILE Attributes.vi
trunk/lvzip/source/fileutil.llb/FILE Create Link.vi
trunk/lvzip/source/fileutil.llb/FILE Get Directory Content.vi
trunk/lvzip/source/fileutil.llb/FILE Read Link Target.vi
trunk/lvzip/source/fileutil.llb/FILE Resource File Info.vi
trunk/lvzip/source/fileutil.llb/FILE VI Tree.vi
Added Paths:
-----------
trunk/lvzip/source/fileutil.llb/PATH Attributes.vi
trunk/lvzip/source/fileutil.llb/PATH Create Link.vi
trunk/lvzip/source/fileutil.llb/PATH Get Directory Content.vi
trunk/lvzip/source/fileutil.llb/PATH Read Link Target.vi
trunk/lvzip/source/fileutil.llb/PSTR Attributes.vi
trunk/lvzip/source/fileutil.llb/PSTR Create Link.vi
trunk/lvzip/source/fileutil.llb/PSTR Get Directory Content.vi
trunk/lvzip/source/fileutil.llb/PSTR Read Link Target.vi
trunk/lvzip/source/fileutil.llb/UTIL Is Little Endian.vi
Modified: trunk/lvzip/source/fileutil.llb/FILE Attributes.ctl
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/fileutil.llb/FILE Attributes.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/fileutil.llb/FILE Create Link.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/fileutil.llb/FILE Get Directory Content.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/fileutil.llb/FILE Read Link Target.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/fileutil.llb/FILE Resource File Info.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/fileutil.llb/FILE VI Tree.vi
===================================================================
(Binary files differ)
Added: trunk/lvzip/source/fileutil.llb/PATH Attributes.vi
===================================================================
(Binary files differ)
Index: trunk/lvzip/source/fileutil.llb/PATH Attributes.vi
===================================================================
--- trunk/lvzip/source/fileutil.llb/PATH Attributes.vi 2019-10-03 23:11:34 UTC (rev 1612)
+++ trunk/lvzip/source/fileutil.llb/PATH Attributes.vi 2019-10-03 23:12:40 UTC (rev 1613)
Property changes on: trunk/lvzip/source/fileutil.llb/PATH Attributes.vi
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Added: trunk/lvzip/source/fileutil.llb/PATH Create Link.vi
===================================================================
(Binary files differ)
Index: trunk/lvzip/source/fileutil.llb/PATH Create Link.vi
===================================================================
--- trunk/lvzip/source/fileutil.llb/PATH Create Link.vi 2019-10-03 23:11:34 UTC (rev 1612)
+++ trunk/lvzip/source/fileutil.llb/PATH Create Link.vi 2019-10-03 23:12:40 UTC (rev 1613)
Property changes on: trunk/lvzip/source/fileutil.llb/PATH Create Link.vi
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Added: trunk/lvzip/source/fileutil.llb/PATH Get Directory Content.vi
===================================================================
(Binary files differ)
Index: trunk/lvzip/source/fileutil.llb/PATH Get Directory Content.vi
===================================================================
--- trunk/lvzip/source/fileutil.llb/PATH Get Directory Content.vi 2019-10-03 23:11:34 UTC (rev 1612)
+++ trunk/lvzip/source/fileutil.llb/PATH Get Directory Content.vi 2019-10-03 23:12:40 UTC (rev 1613)
Property changes on: trunk/lvzip/source/fileutil.llb/PATH Get Directory Content.vi
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Added: trunk/lvzip/source/fileutil.llb/PATH Read Link Target.vi
===================================================================
(Binary files differ)
Index: trunk/lvzip/source/fileutil.llb/PATH Read Link Target.vi
===================================================================
--- trunk/lvzip/source/fileutil.llb/PATH Read Link Target.vi 2019-10-03 23:11:34 UTC (rev 1612)
+++ trunk/lvzip/source/fileutil.llb/PATH Read Link Target.vi 2019-10-03 23:12:40 UTC (rev 1613)
Property changes on: trunk/lvzip/source/fileutil.llb/PATH Read Link Target.vi
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Added: trunk/lvzip/source/fileutil.llb/PSTR Attributes.vi
===================================================================
(Binary files differ)
Index: trunk/lvzip/source/fileutil.llb/PSTR Attributes.vi
===================================================================
--- trunk/lvzip/source/fileutil.llb/PSTR Attributes.vi 2019-10-03 23:11:34 UTC (rev 1612)
+++ trunk/lvzip/source/fileutil.llb/PSTR Attributes.vi 2019-10-03 23:12:40 UTC (rev 1613)
Property changes on: trunk/lvzip/source/fileutil.llb/PSTR Attributes.vi
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Added: trunk/lvzip/source/fileutil.llb/PSTR Create Link.vi
===================================================================
(Binary files differ)
Index: trunk/lvzip/source/fileutil.llb/PSTR Create Link.vi
===================================================================
--- trunk/lvzip/source/fileutil.llb/PSTR Create Link.vi 2019-10-03 23:11:34 UTC (rev 1612)
+++ trunk/lvzip/source/fileutil.llb/PSTR Create Link.vi 2019-10-03 23:12:40 UTC (rev 1613)
Property changes on: trunk/lvzip/source/fileutil.llb/PSTR Create Link.vi
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Added: trunk/lvzip/source/fileutil.llb/PSTR Get Directory Content.vi
===================================================================
(Binary files differ)
Index: trunk/lvzip/source/fileutil.llb/PSTR Get Directory Content.vi
===================================================================
--- trunk/lvzip/source/fileutil.llb/PSTR Get Directory Content.vi 2019-10-03 23:11:34 UTC (rev 1612)
+++ trunk/lvzip/source/fileutil.llb/PSTR Get Directory Content.vi 2019-10-03 23:12:40 UTC (rev 1613)
Property changes on: trunk/lvzip/source/fileutil.llb/PSTR Get Directory Content.vi
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Added: trunk/lvzip/source/fileutil.llb/PSTR Read Link Target.vi
===================================================================
(Binary files differ)
Index: trunk/lvzip/source/fileutil.llb/PSTR Read Link Target.vi
===================================================================
--- trunk/lvzip/source/fileutil.llb/PSTR Read Link Target.vi 2019-10-03 23:11:34 UTC (rev 1612)
+++ trunk/lvzip/source/fileutil.llb/PSTR Read Link Target.vi 2019-10-03 23:12:40 UTC (rev 1613)
Property changes on: trunk/lvzip/source/fileutil.llb/PSTR Read Link Target.vi
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Added: trunk/lvzip/source/fileutil.llb/UTIL Is Little Endian.vi
===================================================================
(Binary files differ)
Index: trunk/lvzip/source/fileutil.llb/UTIL Is Little Endian.vi
===================================================================
--- trunk/lvzip/source/fileutil.llb/UTIL Is Little Endian.vi 2019-10-03 23:11:34 UTC (rev 1612)
+++ trunk/lvzip/source/fileutil.llb/UTIL Is Little Endian.vi 2019-10-03 23:12:40 UTC (rev 1613)
Property changes on: trunk/lvzip/source/fileutil.llb/UTIL Is Little Endian.vi
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <lab...@us...> - 2019-09-23 08:11:44
|
Revision: 1611
http://sourceforge.net/p/opengtoolkit/svn/1611
Author: labviewer
Date: 2019-09-23 08:11:42 +0000 (Mon, 23 Sep 2019)
Log Message:
-----------
More file util improvements
Modified Paths:
--------------
trunk/lvzip/source/fileutil.llb/FILE Attributes.ctl
trunk/lvzip/source/fileutil.llb/FILE Attributes.vi
trunk/lvzip/source/fileutil.llb/FILE Get Directory Content.vi
trunk/lvzip/source/fileutil.llb/FILE Open File Refnum.vi
trunk/lvzip/source/fileutil.llb/FILE Read Link Target.vi
trunk/lvzip/source/lvzip.llb/ZLIB Convert File Info.vi
trunk/lvzip/source/lvzip.llb/ZLIB VI Tree.vi
Modified: trunk/lvzip/source/fileutil.llb/FILE Attributes.ctl
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/fileutil.llb/FILE Attributes.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/fileutil.llb/FILE Get Directory Content.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/fileutil.llb/FILE Open File Refnum.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/fileutil.llb/FILE Read Link Target.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Convert File Info.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB VI Tree.vi
===================================================================
(Binary files differ)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <lab...@us...> - 2019-09-23 08:09:54
|
Revision: 1610
http://sourceforge.net/p/opengtoolkit/svn/1610
Author: labviewer
Date: 2019-09-23 08:09:52 +0000 (Mon, 23 Sep 2019)
Log Message:
-----------
More file util improvements
Modified Paths:
--------------
trunk/lvzip/c_source/lvapi.c
trunk/lvzip/c_source/lvutil.c
trunk/lvzip/c_source/lvutil.h
Modified: trunk/lvzip/c_source/lvapi.c
===================================================================
--- trunk/lvzip/c_source/lvapi.c 2019-09-17 07:25:17 UTC (rev 1609)
+++ trunk/lvzip/c_source/lvapi.c 2019-09-23 08:09:52 UTC (rev 1610)
@@ -198,9 +198,9 @@
LibAPI(uInt32) lvzlib_isLittleEndian(void)
{
#if BigEndian
- return FALSE;
+ return LV_FALSE;
#else
- return TRUE;
+ return LV_TRUE;
#endif
}
@@ -257,7 +257,7 @@
MgErr err = lvzlibCreateRefnum(node, refnum, ZipMagic, LV_FALSE);
if (!err && comment)
{
- int32 len = (int32)strlen(comment);
+ int32 len = (int32)StrLen((ConstCStr)comment);
if (len > 0)
{
err = NumericArrayResize(uB, 1, (UHandle*)globalcomment, len);
@@ -560,31 +560,16 @@
* 2 - case insensitive
*
****************************************************************************************************/
-#if Win32
-#define strcasecmp _stricmp
-#endif
-
static int caseInsensitiveNameComparer(unzFile file, const char *filename1, const char *filename2)
{
Unused(file);
-#if VxWorks
- int32 c1, c2;
-
- while (((c1 = *filename1++) == (c2 = *filename2++)) || (tolower(c1) == tolower(c2)))
- if(c1 == '\0')
- return 0;
- c1 = tolower(c1);
- c2 = tolower(c2);
- return c1 - c2;
-#else
- return strcasecmp(filename1, filename2);
-#endif
+ return StrNCaseCmp((ConstCStr)filename1, (ConstCStr)filename2, StrLen((ConstCStr)filename1));
}
static int caseSensitiveNameComparer(unzFile file, const char *filename1, const char *filename2)
{
Unused(file);
- return strcmp(filename1, filename2);
+ return StrCmp((ConstCStr)filename1, (ConstCStr)filename2);
}
LibAPI(MgErr) lvzlib_unzLocateFile(LVRefNum *refnum, LStrHandle fileName, int iCaseSensitivity)
Modified: trunk/lvzip/c_source/lvutil.c
===================================================================
--- trunk/lvzip/c_source/lvutil.c 2019-09-17 07:25:17 UTC (rev 1609)
+++ trunk/lvzip/c_source/lvutil.c 2019-09-23 08:09:52 UTC (rev 1610)
@@ -150,12 +150,17 @@
#define FCNTL_PARAM3_CAST(param) (int32)(param)
#else
#define FCNTL_PARAM3_CAST(param) (param)
+ #define st_ctimespec st_ctim
+ #define st_atimespec st_atim
+ #define st_mtimespec st_mtim
#endif
#elif MacOSX
#include <CoreFoundation/CoreFoundation.h>
#include <CoreServices/CoreServices.h>
+ #include <sys/types.h>
#include <sys/stat.h>
#include <sys/xattr.h>
+ #include <dirent.h>
#define ftruncate64 ftruncate
#if ProcessorType!=kX64
#define MacSpec FSRef
@@ -166,8 +171,6 @@
#define MacIsAlias(cpb) ((cpb).hFileInfo.ioFlFndrInfo.fdFlags & kIsAlias)
#define kFileChanged (1L<<7)
static MgErr OSErrToLVErr(OSErr err);
- #else
- #include <dirent.h>
#endif
#endif
@@ -191,27 +194,29 @@
#endif
#if usesWinPath && !defined(EMBEDDED)
-#define LWStrPtr WStrPtr
-#define LWStrLen WStrLen
-#define LWStrBuf WStrBuf
+#define LWStrPtr WStrPtr
+#define LWStrLen(p) WStrLen(p)
+#define LWStrBuf(p) WStrBuf(p)
+#define LWStrLenSet(p, s) WStrLenSet(p, s)
-#define LWStrNCat WStrNCat
-#define lwslen wcslen
-#define lwsrchr wcsrchr
+#define LWStrNCat WStrNCat
+#define lwslen wcslen
+#define lwsrchr wcsrchr
static const wchar_t strWildcardPattern[] = L"*.*";
#else
-#define LWStrPtr LStrPtr
-#define LWStrLen LStrLen
-#define LWStrBuf LStrBuf
+#define LWStrPtr LStrPtr
+#define LWStrLen(p) LStrLen(p)
+#define LWStrBuf(p) LStrBuf(p)
+#define LWStrLenSet(p, s) LStrLen(p) = s
-#define LWStrNCat LStrNCat
-#define lwslen strlen
-#define lwsrchr strrchr
+#define LWStrNCat LStrNCat
+#define lwslen strlen
+#define lwsrchr strrchr
static char strWildcardPattern[] = "*.*";
-#define SStrBuf(s) (char*)LStrBuf(s)
+#define SStrBuf(s) (char*)LStrBuf(s)
#endif
#ifdef HAVE_BZIP2
@@ -374,8 +379,10 @@
a = s = t;
e = s + len;
if (!*s || !len)
+ {
+ *s = '\0';
return noErr;
-
+ }
/*
\\?\UNC\server\share
\\?\C:\
@@ -397,7 +404,7 @@
{
n += 2;
s += 2;
- if ((s[0] == 'U' || s[0] == 'u') && (s[1] == 'N' || s[1] == 'n') && (s[2] == 'C' || s[2] == 'C') && s[2] == kPathSeperator)
+ if ((s[0] == 'U' || s[0] == 'u') && (s[1] == 'N' || s[1] == 'n') && (s[2] == 'C' || s[2] == 'C') && s[3] == kPathSeperator)
{
unc = TRUE;
n += 4;
@@ -530,7 +537,7 @@
static void UnixConvertToATime(struct timespec *sTime, ATime128 *time)
{
- time->u.f.val = (int64_t)(sTime->tv_sec + dt1970re1904);
+ time->u.f.val = (int64_t)sTime->tv_sec + dt1970re1904;
time->u.p.fractHi = (uint32_t)sTime->tv_nsec * 4.294967296;
time->u.p.fractLo = 0;
}
@@ -569,10 +576,10 @@
static MgErr NormalizePath(LWStrPtr lwstr)
{
- char *a, s, e, t = LWStrBuf(lwstr);
+ char *a, *s, *e, *t;
int32 len = LWStrLen(lwstr);
- a = s = t;
+ a = s = t = LWStrBuf(lwstr);
e = s + len;
if (!*s || !len)
return noErr;
@@ -580,48 +587,36 @@
/* Canonicalize the path */
while (s < e)
{
- if (s[0] == kPosixPathSeperator)
+ if (s[0] == kPosixPathSeperator && s[1] == kPosixPathSeperator)
{
- if (s[1] == kPosixPathSeperator)
s++; /* Reduce // to / */
}
else if (s[0] == '.')
{
- if (s[1] == kPosixPathSeperator && (s == a || s[-1] == kPosixPathSeperator))
+ if (s[1] == kPosixPathSeperator && (s == a && s[-1] == kPosixPathSeperator))
{
s += 2; /* Skip ./ */
}
- else if (s[1] == '.' && (t == a || t[-1] == kPosixPathSeperator))
+ else if (s[1] == '.')
{
- /* .. backs up a directory
+ /* .. backs up a directory but only if it is not at the root of the path
*/
- if (t != a)
+ if (t == a || t > a + 2 && t[-1] == kPosixPathSeperator && t[-2] == '.')
{
- if (t > a + 1 && t[-1] == kPosixPathSeperator &&
- (t[-2] != kPosixPathSeperator || t > a + 2))
- {
- if (t[-2] == ':' && (t > a + 3 || t[-3] == ':'))
- {
- t -= 2;
- while (t > a && *t != kPosixPathSeperator)
- t--;
- if (*t == kPosixPathSeperator)
- t++; /* Reset to last '\' */
- else
- t = a; /* Start path again from new root */
- }
- else if (t[-2] != ':' && !unc)
- t -= 2;
- }
+ *t++ = *s++;
+ *t++ = *s++;
+ }
+ else if (t > a + 2 && t[-1] == kPosixPathSeperator && (t[-2] != kPosixPathSeperator))
+ {
+ t -= 2;
while (t > a && *t != kPosixPathSeperator)
t--;
- if (t == a)
- {
- *t = kPosixPathSeperator;
- s++;
- }
+ if (*t == kPosixPathSeperator)
+ t++; /* Reset to last '\' */
+ s += 3; /* Skip ../ in src path */
}
- s += 2; /* Skip .. in src path */
+ else
+ return mgArgErr;
}
else
*t++ = *s++;
@@ -629,13 +624,15 @@
else
*t++ = *s++;
}
- *t++ = '\0';
+ if (*t == kPosixPathSeperator && t > a + 1)
+ t--;
+ *t = '\0';
return noErr;
}
#endif
#if Unix || MacOSX || defined(EMBEDDED)
-static MgErr makeFileDSString(LStrHandle string, uInt32 codePage, LWStrPtr *lwstr, size_t *reserve)
+static MgErr makeFileDSString(LStrHandle string, uInt32 codePage, LWStrPtr *lwstr, int32 *reserve)
{
MgErr err = noErr;
LStrHandle dest = NULL;
@@ -678,7 +675,7 @@
#if Unix || MacOSX
else
{
- LStrBuf(*lwstr)[0] = kPathSeparator;
+ LStrBuf(*lwstr)[0] = kPathSeperator;
LStrLen(*lwstr) = 1;
}
#endif
@@ -698,7 +695,8 @@
off = LStrLen(lstr);
if (off + strLen < bufLen)
{
- strncpy(LStrBuf(lstr) + off, str, strLen + 1);
+ strncpy(LStrBuf(lstr) + off, str, strLen);
+ LStrBuf(lstr)[off + strLen] = 0;
LStrLen(lstr) = off + strLen;
return noErr;
}
@@ -717,12 +715,12 @@
if (bufLen <= 0)
return Win32GetLVFileErr();
- if (isalpha(buf[0]) && buf[1] == ':')
+ if (iswalpha(buf[0]) && buf[1] == ':')
{
/* Absolute path with drive letter */
len = 4;
}
- else if (buf[0] == kPathSeperator && buf[1] == kPathSeperator && isalpha(buf[2]))
+ else if (buf[0] == kPathSeperator && buf[1] == kPathSeperator && iswalpha(buf[2]))
{
/* Absolute UNC path */
len = 7;
@@ -770,7 +768,8 @@
off = WStrLen(wstr);
if (off + strLen < bufLength)
{
- wcsncpy(WStrBuf(wstr) + off, str, strLen + 1);
+ wcsncpy(WStrBuf(wstr) + off, str, strLen);
+ WStrBuf(wstr)[off + strLen] = 0;
WStrLenSet(wstr, off + strLen);
return noErr;
}
@@ -777,23 +776,27 @@
return mgArgErr;
}
-#define Win32HasDOSDevicePrefix(str) (str[0] == kPathSeperator && str[1] == kPathSeperator && (str[2] == '?' || str[2] == '.') && str[3] == kPathSeperator)
+#define Win32HasDOSDevicePrefix(str, len) (len >= 4 && str[0] == kPathSeperator && str[1] == kPathSeperator && (str[2] == '?' || str[2] == '.') && str[3] == kPathSeperator)
-LibAPI(MgErr) Win32ResolveShortCut(WStrPtr wStr, WStrPtr *wTgt, int32 *bufLen, Bool32 recursive, DWORD *dwAttrs)
+static WCHAR *extStr = L".LNK";
+
+static int Win32CanBeShortcutLink(WCHAR *str, int32 len)
{
+ int32 extLen = (int32)wcslen(extStr);
+ return (len >= extLen && !_wcsicmp(str + len - extLen, extStr));
+}
+
+LibAPI(MgErr) Win32ResolveShortCut(WStrPtr wStr, WStrPtr *wTgt, int32 *bufLen, uInt32 flags, DWORD *dwAttrs)
+{
HRESULT err = noErr;
IShellLinkW* psl;
IPersistFile* ppf;
WIN32_FIND_DATAW fileData;
- WCHAR *extStr = L".LNK";
- WCHAR tempPath[MAX_PATH], *srcPath = WStrBuf(wStr);
- int32 len = WStrLen(wStr), extLen = (int32)wcslen(extStr);
+ WCHAR tempPath[MAX_PATH * 4], *srcPath = WStrBuf(wStr);
// Don't bother trying to resolve shortcut if it doesn't have a ".lnk" extension.
- if (len < extLen)
+ if (!Win32CanBeShortcutLink(srcPath, WStrLen(wStr)))
return cancelError;
- if (_wcsicmp(srcPath + len - extLen, extStr))
- return cancelError;
// Get a pointer to the IShellLink interface.
err = CoCreateInstance(&CLSID_ShellLink, NULL, CLSCTX_INPROC_SERVER, &IID_IShellLinkW, (void**)&psl);
@@ -812,14 +815,14 @@
if (SUCCEEDED(err))
{
fileData.dwFileAttributes = INVALID_FILE_ATTRIBUTES;
- err = IShellLinkW_GetPath(psl, tempPath, MAX_PATH, &fileData, SLGP_SHORTPATH);
+ err = IShellLinkW_GetPath(psl, tempPath, MAX_PATH * 4, &fileData, SLGP_RAWPATH);
if (SUCCEEDED(err))
{
*dwAttrs = fileData.dwFileAttributes;
if (err == S_OK)
{
- len = (int32)wcslen(tempPath);
- if (recursive && len >= extLen && !_wcsicmp(tempPath + len - extLen, extStr))
+ int32 len = (int32)wcslen(tempPath);
+ if (flags & kRecursive && Win32CanBeShortcutLink(tempPath, len))
{
srcPath = tempPath;
continue;
@@ -888,48 +891,49 @@
return success;
}
-LibAPI(MgErr) Win32ResolveLink(WStrPtr wSrc, WStrPtr *wTgt, int32 *bufLen, Bool32 recursive, DWORD *dwAttrs)
+LibAPI(MgErr) Win32ResolveLink(WStrPtr wSrc, WStrPtr *wTgt, int32 *bufLen, int32 flags, DWORD *dwAttrs)
{
HANDLE handle;
MgErr err = noErr;
- int32 length, parentLen = 0, offset;
DWORD bytes = MAXIMUM_REPARSE_DATA_BUFFER_SIZE;
PREPARSE_DATA_BUFFER buffer = NULL;
- WStrPtr tempPath = NULL, wIntermediate = wSrc;
+ WStrPtr wIntermediate = wSrc;
*dwAttrs = GetFileAttributes(wSrc);
if (*dwAttrs == INVALID_FILE_ATTRIBUTES)
- {
return Win32GetLVFileErr();
- }
+ if (!(*dwAttrs & FILE_ATTRIBUTE_REPARSE_POINT))
+ return mgNoErr;
+
// Need to acquire backup privileges in order to be able to retrieve a handle to a directory below or call symlink kernel entry points
Win32ModifyBackupPrivilege(TRUE);
- while (!err && *dwAttrs & FILE_ATTRIBUTE_REPARSE_POINT)
+ do
{
// Open the link file or directory
handle = CreateFile(wIntermediate, GENERIC_READ, 0 /*FILE_SHARE_READ|FILE_SHARE_WRITE|FILE_SHARE_DELETE */,
NULL, OPEN_EXISTING, FILE_FLAG_OPEN_REPARSE_POINT | FILE_FLAG_BACKUP_SEMANTICS, NULL);
if (handle == INVALID_HANDLE_VALUE)
- {
- err = Win32GetLVFileErr();
- }
+ return Win32GetLVFileErr();
- if (!err)
+ if (!buffer)
+ buffer = (PREPARSE_DATA_BUFFER)DSNewPtr(bytes);
+ if (buffer)
{
- if (!buffer)
- buffer = (PREPARSE_DATA_BUFFER)DSNewPtr(bytes);
if (!DeviceIoControl(handle, FSCTL_GET_REPARSE_POINT, NULL, 0, buffer, bytes, &bytes, NULL))
err = Win32GetLVFileErr();
else if (bytes < 9)
err = fEOF;
-
- // Close the handle to our file so we're not locking it anymore.
- CloseHandle(handle);
}
+ else
+ err = mFullErr;
+ // Close the handle to our file so we're not locking it anymore.
+ CloseHandle(handle);
+
if (!err)
{
+ int32 length;
BOOL relative = FALSE;
LPWSTR start = NULL;
@@ -951,53 +955,90 @@
}
if (length)
{
- parentLen = 0;
- if (length > 4 && Win32HasDOSDevicePrefix(start))
+ WStrPtr tempPath = NULL;
+ int32 offset = 0, parentLen = 0, intLen = length;
+ if (Win32HasDOSDevicePrefix(start, length))
{
- relative = FALSE;
- start += 4;
+ offset = 4;
+ if (length >= 7 && towlower(start[4]) == 'u' && towlower(start[5]) == 'n' && towlower(start[6]) == 'c' && start[7] == kPathSeperator)
+ {
+ relative = FALSE;
+ }
}
- else if (!relative)
+ else
{
- length += 4;
+ if (length >= 2 && start[0] == kPathSeperator && start[1] == kPathSeperator)
+ {
+ relative = FALSE;
+ offset = 1;
+ intLen += 6;
+ }
}
+ if (length - offset >= 3 && isalpha(start[offset]) && start[offset + 1] == ':' && start[offset + 2] == kPathSeperator)
+ {
+ relative = FALSE;
+ intLen += (4 - offset);
+ }
+ intLen++;
if (relative)
{
- /* Shorten the path to the parent directory */
wchar_t *ptr = WStrBuf(wIntermediate);
parentLen = WStrLen(wIntermediate);
- while (parentLen && ptr[--parentLen] != kPathSeperator);
+ while (ptr[--parentLen] != kPathSeperator);
parentLen++;
- length += parentLen;
+ intLen = parentLen + length + 1;
}
-
- tempPath = (WStrPtr)DSNewPtr(sizeof(int32) + sizeof(WCHAR) * ++length);
+
+ tempPath = (WStrPtr)DSNewPtr(sizeof(int32) + sizeof(WCHAR) * intLen);
if (tempPath)
{
if (relative)
{
- WStrNCat(tempPath, 0, parentLen, WStrBuf(wIntermediate), WStrLen(wIntermediate));
+ if (start[0] == kPathSeperator)
+ {
+ parentLen--;
+ }
+ err = WStrNCat(tempPath, 0, intLen, WStrBuf(wIntermediate), parentLen);
offset = parentLen;
}
+ else if (offset == 1)
+ {
+ err = WStrNCat(tempPath, 0, intLen, L"\\\\?\\UNC", 7);
+ }
else
{
- WStrNCat(tempPath, 0, length, L"\\\\?\\", 4);
- offset = 4;
+ err = WStrNCat(tempPath, 0, intLen, L"\\\\?\\", 4);
}
if (wIntermediate != wSrc)
DSDisposePtr((UPtr)wIntermediate);
+ wIntermediate = tempPath;
- WStrNCat(tempPath, offset, length - offset, start, length - offset);
+ if (!err)
+ err = WStrNCat(wIntermediate, -1, intLen, start + offset, length - offset);
+
+ if (!err)
+ {
+ *dwAttrs = GetFileAttributes(wIntermediate);
+ if (*dwAttrs == INVALID_FILE_ATTRIBUTES)
+ {
+ err = Win32GetLVFileErr();
+ }
+ else if (!(flags & kRecursive) || !(*dwAttrs & FILE_ATTRIBUTE_REPARSE_POINT))
+ {
+ if (relative && !(flags & kResolveRel))
+ err = WStrNCat(wIntermediate, 0, intLen, start, length);
- *dwAttrs = GetFileAttributes(tempPath);
- if (!recursive)
- break;
-
- if (*dwAttrs == INVALID_FILE_ATTRIBUTES)
- err = Win32GetLVFileErr();
-
- wIntermediate = tempPath;
+ if (!err && wTgt)
+ {
+ DSDisposePtr((UPtr)*wTgt);
+ *wTgt = wIntermediate;
+ if (bufLen)
+ *bufLen = intLen;
+ return noErr;
+ }
+ }
+ }
}
else
{
@@ -1004,20 +1045,14 @@
err = mFullErr;
}
}
+ else
+ err = fIOErr;
}
- }
+ } while (!err);
Win32ModifyBackupPrivilege(FALSE);
DSDisposePtr((UPtr)buffer);
- if (!err && wTgt)
- {
- DSDisposePtr((UPtr)*wTgt);
- *wTgt = tempPath;
- return noErr;
- }
- else
- {
- DSDisposePtr((UPtr)tempPath);
- }
+ if (wIntermediate != wSrc)
+ DSDisposePtr((UPtr)wIntermediate);
return err;
}
#endif
@@ -1037,12 +1072,12 @@
len = strlen(ptr);
#endif
/* look backwards */
- for ( ; k < len && k < kMaxFileExtLength; --ptr, k++)
+ for (ptr += len; k < len && k < kMaxFileExtLength; --ptr, k++)
{
if (*ptr == '.')
{
uChar str[16];
- PStrLen(str) = (uChar)k;
+ PStrLen(str) = (uChar)k - 1;
for (len = 1; k; k--)
str[len++] = (uChar)*ptr++;
return PStrHasRezExt(str);
@@ -1060,7 +1095,8 @@
return mgArgErr;
}
LWStrBuf(pathName)[LWStrLen(pathName)] = kPathSeperator;
- LWStrBuf(pathName)[LWStrLen(pathName) + 1] = 0;
+ LWStrLenSet(pathName, LWStrLen(pathName) + 1);
+ LWStrBuf(pathName)[LWStrLen(pathName)] = 0;
}
return noErr;
}
@@ -1106,7 +1142,7 @@
On Windows the pathName is a wide char Long String pointer and the function returns UTF8 encoded filenames in the name array
On other platforms it uses whatever is the default encoding for both pathName and the filenames, which could be UTF8 (Linux and Mac)
*/
-static MgErr lvFile_ListDirectory(LWStrPtr pathName, int32 bufLen, LStrArrHdl *nameArr, FileInfoArrHdl *typeArr, int32 flags)
+static MgErr lvFile_ListDirectory(LWStrPtr pathName, int32 bufLen, LStrArrHdl *nameArr, FileInfoArrHdl *typeArr, uInt32 cp, int32 flags)
{
MgErr err;
int32 rootLength, type, index = 0, size = 8;
@@ -1132,7 +1168,6 @@
#endif
#endif
-#if Win32
err = NumericArrayResize(uPtr, 1, (UHandle*)nameArr, size);
if (err)
return err;
@@ -1141,6 +1176,7 @@
if (err)
return err;
+#if Win32
if (!pathName || !LWStrLen(pathName))
{
DWORD drives = GetLogicalDrives();
@@ -1249,10 +1285,9 @@
{
(**typeArr)->elm[index].flags |= kIsLink;
}
- else
+ else if (!Win32ResolveShortCut(pathName, NULL, NULL, 0, &dwAttrs))
{
- if (!Win32ResolveShortCut(pathName, NULL, NULL, FALSE, &dwAttrs))
- (**typeArr)->elm[index].flags |= (kIsLink | kIsFile);
+ (**typeArr)->elm[index].flags |= (kIsLink | kIsFile);
}
#endif
if (!(dwAttrs & FILE_ATTRIBUTE_DIRECTORY))
@@ -1280,9 +1315,9 @@
(**typeArr)->elm[index].flags |= kErrGettingType | kIsFile;
}
#if EMBEDDED
- err = ConvertCString(fileName, -1, CP_ACP, (**nameArr)->elm + index, CP_ACP, 0, NULL);
+ err = ConvertCString(fileName, -1, CP_ACP, (**nameArr)->elm + index, cp, 0, NULL);
#else
- err = WideCStrToMultiByte(fileName, -1, (**nameArr)->elm + index, CP_UTF8, 0, NULL);
+ err = WideCStrToMultiByte(fileName, -1, (**nameArr)->elm + index, cp, 0, NULL);
#endif
index++;
(**nameArr)->numItems = index;
@@ -1302,18 +1337,11 @@
#endif
if (dirp != INVALID_HANDLE_VALUE)
FindClose(dirp);
- if (index < size)
- {
- if (*nameArr || index > 0)
- NumericArrayResize(uPtr, 1, (UHandle*)nameArr, index);
- if (*typeArr || index > 0)
- NumericArrayResize(uQ, 1, (UHandle*)typeArr, index);
- }
#else
if (!pathName || !LWStrLen(pathName))
path = "/";
else
- path = SStrBuf(pathName):
+ path = SStrBuf(pathName);
/* Check that we have actually a folder */
if (lstat(path, &statbuf))
@@ -1330,13 +1358,9 @@
if (err)
return err;
- if (!(dirp = opendir(path))))
+ if (!(dirp = opendir(path)))
return UnixToLVFileErr();
- /* Skip . and .. directory entries, they're always the first two. */
- (void)readdir(dirp);
- (void)readdir(dirp);
-
err = LWAppendPathSeparator(pathName, bufLen);
if (err)
goto FListDirOut;
@@ -1343,9 +1367,10 @@
rootLength = LWStrLen(pathName);
- for (dp = readdir(dirp), index = 1; dp; dp = readdir(dirp), index++)
+ for (dp = readdir(dirp); dp; dp = readdir(dirp))
{
- /* Skip the current dir, and parent dir entries */
+ /* Skip the current dir, and parent dir entries. They are not guaranteed to be always the first
+ two entries enumerated! */
if (dp->d_name[0] != '.' || (dp->d_name[1] != 0 && (dp->d_name[1] != '.' || dp->d_name[2] != 0)))
{
if (index >= size)
@@ -1360,11 +1385,11 @@
goto FListDirOut;
}
- err = ConvertCString(dp->d_name, -1, CP_ACP, (**nameArr)->elm + index, CP_ACP, 0, NULL);
+ err = ConvertCString(dp->d_name, -1, CP_ACP, (**nameArr)->elm + index, cp, 0, NULL);
if (err)
goto FListDirOut;
- err = LStrNCat(pathName, rootLength, bufLen, dp->d_name);
+ err = LWStrNCat(pathName, rootLength, bufLen, dp->d_name, -1);
if (err)
goto FListDirOut;
@@ -1378,7 +1403,7 @@
if (S_ISLNK(statbuf.st_mode))
{
(**typeArr)->elm[index].flags |= kIsLink;
- if (stat(thePath, &tmpstatbuf) == 0) /* If link points to something */
+ if (stat(SStrBuf(pathName), &tmpstatbuf) == 0) /* If link points to something */
statbuf = tmpstatbuf; /* return info about it not link. */
}
#endif
@@ -1385,7 +1410,7 @@
if (!S_ISDIR(statbuf.st_mode))
{
(**typeArr)->elm[index].flags |= kIsFile;
- if (type = PtrHasRezExt(SStrBuf(pathName, LStrLen(pathName))))
+ if (type = PtrHasRezExt(SStrBuf(pathName), LStrLen(pathName)))
{
(**typeArr)->elm[index].flags |= kRecognizedType;
(**typeArr)->elm[index].type = type;
@@ -1400,10 +1425,18 @@
FListDirOut:
closedir(dirp);
#endif
+ if (index < size)
+ {
+ if (*nameArr || index > 0)
+ NumericArrayResize(uPtr, 1, (UHandle*)nameArr, index);
+ if (*typeArr || index > 0)
+ NumericArrayResize(uQ, 1, (UHandle*)typeArr, index);
+ }
return err;
}
-/* On Windows, folderPath is a UTF8 encoded string, on other platforms it is locally encoded */
+/* On Windows and Mac, folderPath is a UTF8 encoded string, on other platforms it is locally encoded but
+ this could be UTF8 (Linux, depending on its configuration) */
LibAPI(MgErr) LVFile_ListDirectory(LStrHandle folderPath, LStrArrHdl *nameArr, FileInfoArrHdl *typeArr, int32 flags)
{
MgErr err = mgArgErr;
@@ -1413,16 +1446,18 @@
if (LStrLenH(folderPath))
#endif
{
- bufLen = 260;
+ bufLen = 280;
err = MakeFileDSString(folderPath, &pathName, &bufLen);
if (err)
return err;
}
- err = lvFile_ListDirectory(pathName, bufLen, nameArr, typeArr, flags);
+ err = lvFile_ListDirectory(pathName, bufLen, nameArr, typeArr, CP_UTF8, flags);
DSDisposePtr((UPtr)pathName);
return err;
}
+/* This is the LabVIEW Path version of above function. It's strings are always locally encoded so there
+ can be a problem with paths on Windows and other systems that don't use UTF8 as local encoding */
LibAPI(MgErr) LVPath_ListDirectory(Path folderPath, LStrArrHdl *nameArr, FileInfoArrHdl *typeArr, int32 flags)
{
MgErr err = mgArgErr;
@@ -1435,12 +1470,12 @@
if (FDepth(folderPath) > 0)
#endif
{
- bufLen = 260;
+ bufLen = 280;
err = MakePathDSString(folderPath, &pathName, &bufLen);
if (err)
return err;
}
- err = lvFile_ListDirectory(pathName, bufLen, nameArr, typeArr, flags);
+ err = lvFile_ListDirectory(pathName, bufLen, nameArr, typeArr, CP_ACP, flags);
DSDisposePtr((UPtr)pathName);
}
return err;
@@ -1637,7 +1672,9 @@
{
count = 1;
- err = LWStrNCat(pathName, 0, bufLen, strWildcardPattern, 3);
+ err = LWAppendPathSeparator(pathName, bufLen);
+ if (!err)
+ err = LWStrNCat(pathName, 0, bufLen, strWildcardPattern, 3);
if (!err)
{
handle = FindFirstFile(pathName, &fi);
@@ -1734,9 +1771,9 @@
VxWorksConvertToATime(statbuf.st_atime, &fileInfo->aDate);
VxWorksConvertToATime(statbuf.st_mtime, &fileInfo->mDate);
#else
- UnixConvertToATime(&statbuf.st_ctim, &fileInfo->cDate);
- UnixConvertToATime(&statbuf.st_mtim, &fileInfo->mDate);
- UnixConvertToATime(&statbuf.st_atim, &fileInfo->aDate);
+ UnixConvertToATime(&statbuf.st_ctimespec, &fileInfo->cDate);
+ UnixConvertToATime(&statbuf.st_mtimespec, &fileInfo->mDate);
+ UnixConvertToATime(&statbuf.st_atimespec, &fileInfo->aDate);
#endif
if (S_ISDIR(statbuf.st_mode))
{
@@ -1779,13 +1816,20 @@
static Bool32 LStrIsAbsPath(LStrHandle filePath)
{
int32 len = LStrLenH(filePath);
+ UPtr ptr = LStrBufH(filePath);
#if usesWinPath
- UPtr ptr = LStrBufH(filePath);
- if (!len || (len >= 3 && isalpha(ptr[0]) && ptr[1] == ':' && ptr[2] == kPathSeperator)
+ int32 offset = 0;
#if !EMBEDDED
- || (len >= 3 && ptr[0] == kPathSeperator && ptr[1] == kPathSeperator && isalpha(ptr[2]))
- || (len > 4 && Win32HasDOSDevicePrefix(ptr))
+ if (Win32HasDOSDevicePrefix(ptr, len))
+ {
+ offset = 4;
+ }
#endif
+ if (!len || ((len - offset) >= 3 && isalpha(ptr[offset]) && ptr[offset + 1] == ':' && ptr[offset + 2] == kPathSeperator)
+ || (!offset && len >= 3 && ptr[0] == kPathSeperator && ptr[1] == kPathSeperator && isalpha(ptr[2]))
+#if !EMBEDDED
+ || (offset && len - offset >= 4 && StrNCaseCmp(ptr + offset, (ConstCStr)"UNC\\", 4))
+#endif
)
return LV_TRUE;
#else
@@ -1989,7 +2033,7 @@
if (buffer)
{
wcscpy(namebuf, L"\\\\?\\");
- if (length > 4 && length < MAX_PATH + 4 && Win32HasDOSDevicePrefix(lpTargetFileName))
+ if (length < MAX_PATH + 4 && Win32HasDOSDevicePrefix(lpTargetFileName, length))
{
offset = 4;
}
@@ -2142,11 +2186,60 @@
#endif
}
-LibAPI(MgErr) LVPath_ReadLink(Path path, Path *target, Bool32 recursive, uInt32 *fileType)
+LibAPI(MgErr) LVFile_ReadLink(LStrHandle path, LStrHandle *target, uInt32 flags, uInt32 *fileType)
{
MgErr err = mgNoErr;
LWStrPtr src = NULL;
+#if Win32 && EMBEDDED
+ return mgNotSupported;
+#else
+ err = MakeFileDSString(path, &src, NULL);
+ if (!err)
+ {
+#if MacOSX || Unix
+#else
+ WStrPtr wTgt = NULL;
+ DWORD dwAttr;
+
+ err = Win32ResolveLink(src, &wTgt, NULL, flags, &dwAttr);
+ *fileType = 0;
+ if (!err && wTgt)
+ {
+ int32 offset = 0;
+ if (Win32HasDOSDevicePrefix(WStrBuf(wTgt), WStrLen(wTgt)))
+ offset += 4;
+
+ err = WideCStrToMultiByte(WStrBuf(wTgt) + offset, WStrLen(wTgt) - offset, target, CP_UTF8, 0, NULL);
+ }
+ if (!err)
+ {
+ if (dwAttr & FILE_ATTRIBUTE_REPARSE_POINT)
+ {
+ *fileType |= kIsLink;
+ }
+ if (!(dwAttr & FILE_ATTRIBUTE_DIRECTORY))
+ {
+ *fileType |= kIsFile;
+ }
+ if (dwAttr & FILE_ATTRIBUTE_HIDDEN)
+ {
+ *fileType |= kFIsInvisible;
+ }
+ }
+ DSDisposePtr((UPtr)wTgt);
+#endif
+ DSDisposePtr((UPtr)src);
+ }
+ return err;
+#endif
+}
+
+LibAPI(MgErr) LVPath_ReadLink(Path path, Path *target, uInt32 flags, uInt32 *fileType)
+{
+ MgErr err = mgNoErr;
+ LWStrPtr src = NULL;
+
if (!FIsAbsPath(path))
return mgArgErr;
@@ -2153,6 +2246,9 @@
#if Win32 && EMBEDDED
return mgNotSupported;
#else
+ if (fileType)
+ *fileType = 0;
+
err = MakePathDSString(path, &src, NULL);
if (!err)
{
@@ -2161,7 +2257,7 @@
char *buf = NULL, *ptr = NULL;
int len = 0;
- if (lstat((const char*)LStrBuf(src), &st))
+ if (lstat(SStrBuf(src), &st))
{
err = UnixToLVFileErr();
}
@@ -2181,7 +2277,7 @@
while (!err)
{
- ssize_t retval = readlink((const char*)LStrBuf(src), buf, len);
+ ssize_t retval = readlink(SStrBuf(src), buf, len);
if (retval < 0)
{
err = UnixToLVFileErr();
@@ -2195,10 +2291,11 @@
if (ptr)
{
buf = ptr;
- memmove(buf + LStrLen(src) + 1, buf, retval);
- memmove(buf, LStrBuf(src), LStrLen(src));
- buf[LStrLen(src)] = '/';
- retval += LStrLen(src) + 1;
+ for (ptr = SStrBuf(src) + LStrLen(src); *ptr != kPathSeperator; ptr--);
+ LStrLen(src) = ptr - SStrBuf(src) + 1;
+ memmove(buf + LStrLen(src), buf, retval);
+ memmove(buf, SStrBuf(src), LStrLen(src));
+ retval += LStrLen(src);
}
else
{
@@ -2212,17 +2309,19 @@
{
if (lstat(buf, &st))
{
+ *fileType =
err = UnixToLVFileErr();
}
else if (S_ISLNK(st.st_mode))
{
+ *fileType = kIsLink;
if (stat(buf, &st))
{
err = UnixToLVFileErr();
}
- else
+ else if (!S_ISDIR(st.st_mode))
{
- *fileType = S_ISDIR(st.st_mode) ? kIsLink : kIsLink | kIsFile;
+ *fileType |= kIsFile;
}
}
else
@@ -2256,17 +2355,18 @@
}
#else
WStrPtr wTgt = NULL;
- int32 tgtLen = 0;
+ int32 bufLen = 0;
DWORD dwAttr;
- err = Win32ResolveLink(src, &wTgt, &tgtLen, recursive, &dwAttr);
- *fileType = 0;
+ err = Win32ResolveShortCut(src, &wTgt, &bufLen, flags, &dwAttr);
+ if (err)
+ err = Win32ResolveLink(src, &wTgt, &bufLen, flags, &dwAttr);
if (!err && wTgt)
{
int32 offset = 0;
LStrHandle handle = NULL;
- if (WStrLen(wTgt) > 4 && Win32HasDOSDevicePrefix(WStrBuf(wTgt)))
- offset += 4;
+ if (Win32HasDOSDevicePrefix(WStrBuf(wTgt), WStrLen(wTgt)))
+ offset += 4;
err = WideCStrToMultiByte(WStrBuf(wTgt) + offset, WStrLen(wTgt) - offset, &handle, CP_ACP, 0, NULL);
if (!err)
@@ -2278,12 +2378,16 @@
{
if (dwAttr & FILE_ATTRIBUTE_REPARSE_POINT)
{
- *fileType = kIsLink;
+ *fileType |= kIsLink;
}
- else if (!(dwAttr & FILE_ATTRIBUTE_DIRECTORY))
+ if (!(dwAttr & FILE_ATTRIBUTE_DIRECTORY))
{
- *fileType = kIsFile;
+ *fileType |= kIsFile;
}
+ if (dwAttr & FILE_ATTRIBUTE_HIDDEN)
+ {
+ *fileType |= kFIsInvisible;
+ }
}
DSDisposePtr((UPtr)wTgt);
#endif
Modified: trunk/lvzip/c_source/lvutil.h
===================================================================
--- trunk/lvzip/c_source/lvutil.h 2019-09-17 07:25:17 UTC (rev 1609)
+++ trunk/lvzip/c_source/lvutil.h 2019-09-23 08:09:52 UTC (rev 1610)
@@ -345,6 +345,8 @@
int32 StrNCpy(CStr t, const CStr s, int32 l);
int32 StrLen(ConstCStr str);
int32 StrCmp(ConstCStr str1, ConstCStr str2);
+int32 StrNCmp(ConstCStr, ConstCStr, size_t);
+int32 StrNCaseCmp(ConstCStr, ConstCStr, size_t);
/** @brief Concatenated Pascal string types. */
typedef struct {
@@ -642,10 +644,6 @@
FMListDetails elm[1];
} FileInfoArrRec, *FileInfoArrPtr, **FileInfoArrHdl;
-#define kLinkNone 0x00
-#define kLinkHard 0x01
-#define kLinkDir 0x02
-
/* Our exported functions */
/**************************/
@@ -696,11 +694,24 @@
/* Retrieve file information from the path */
LibAPI(MgErr) LVPath_FileInfo(Path path, uInt8 write, LVFileInfo *fileInfo);
+LibAPI(MgErr) LVFile_FileInfo(LStrHandle path, uInt8 write, LVFileInfo *fileInfo);
+/* Creation flags */
+#define kLinkSoft 0x00
+#define kLinkHard 0x01
+#define kLinkDir 0x02
+
+/* Resolution flags */
+#define kRecursive 0x01
+#define kResolveRel 0x02
+
/* Create and read a link */
LibAPI(MgErr) LVPath_CreateLink(Path path, Path target, uInt32 flags);
-LibAPI(MgErr) LVPath_ReadLink(Path path, Path *target, Bool32 recursive, uInt32 *fileType);
+LibAPI(MgErr) LVFile_CreateLink(LStrHandle path, Path target, uInt32 flags);
+LibAPI(MgErr) LVPath_ReadLink(Path path, Path *target, uInt32 flags, uInt32 *fileType);
+LibAPI(MgErr) LVFile_ReadLink(LStrHandle path, LStrHandle *target, uInt32 flags, uInt32 *fileType);
+
typedef union
{
int64 q;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <lab...@us...> - 2019-09-15 00:40:18
|
Revision: 1608
http://sourceforge.net/p/opengtoolkit/svn/1608
Author: labviewer
Date: 2019-09-15 00:40:14 +0000 (Sun, 15 Sep 2019)
Log Message:
-----------
First implementation of support for symlinks and use of extra fields times to apply to created files
Modified Paths:
--------------
trunk/lvzip/source/fileutil.llb/FILE Attributes.vi
trunk/lvzip/source/lvzip.llb/ZLIB Close Read File.vi
trunk/lvzip/source/lvzip.llb/ZLIB Convert File Info.vi
trunk/lvzip/source/lvzip.llb/ZLIB Copy Raw File.vi
trunk/lvzip/source/lvzip.llb/ZLIB Delete Files From Archive.vi
trunk/lvzip/source/lvzip.llb/ZLIB Entry Type.ctl
trunk/lvzip/source/lvzip.llb/ZLIB Enumerate File Contents Old.vi
trunk/lvzip/source/lvzip.llb/ZLIB Enumerate File Contents.vi
trunk/lvzip/source/lvzip.llb/ZLIB Extract All Files To Dir.vi
trunk/lvzip/source/lvzip.llb/ZLIB Extract File.vi
trunk/lvzip/source/lvzip.llb/ZLIB Extract Stream.vi
trunk/lvzip/source/lvzip.llb/ZLIB Extract.vi
trunk/lvzip/source/lvzip.llb/ZLIB File Info.ctl
trunk/lvzip/source/lvzip.llb/ZLIB File Information.vi
trunk/lvzip/source/lvzip.llb/ZLIB Get Current File Info Old.vi
trunk/lvzip/source/lvzip.llb/ZLIB Get Current File Info.vi
trunk/lvzip/source/lvzip.llb/ZLIB Get File.vi
trunk/lvzip/source/lvzip.llb/ZLIB Go To First File w Info.vi
trunk/lvzip/source/lvzip.llb/ZLIB Go To First File.vi
trunk/lvzip/source/lvzip.llb/ZLIB Go To Next File w Info.vi
trunk/lvzip/source/lvzip.llb/ZLIB Go To Next File.vi
trunk/lvzip/source/lvzip.llb/ZLIB Locate File w. Info.vi
trunk/lvzip/source/lvzip.llb/ZLIB Locate File.vi
trunk/lvzip/source/lvzip.llb/ZLIB Move Raw File.vi
trunk/lvzip/source/lvzip.llb/ZLIB Open Write File.vi
trunk/lvzip/source/lvzip.llb/ZLIB Store File.vi
trunk/lvzip/source/lvzip.llb/ZLIB Store Stream.vi
trunk/lvzip/source/lvzip.llb/ZLIB VI Tree.vi
Modified: trunk/lvzip/source/fileutil.llb/FILE Attributes.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Close Read File.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Convert File Info.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Copy Raw File.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Delete Files From Archive.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Entry Type.ctl
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Enumerate File Contents Old.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Enumerate File Contents.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Extract All Files To Dir.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Extract File.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Extract Stream.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Extract.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB File Info.ctl
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB File Information.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Get Current File Info Old.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Get Current File Info.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Get File.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Go To First File w Info.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Go To First File.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Go To Next File w Info.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Go To Next File.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Locate File w. Info.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Locate File.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Move Raw File.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Open Write File.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Store File.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Store Stream.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB VI Tree.vi
===================================================================
(Binary files differ)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <lab...@us...> - 2019-09-15 00:38:58
|
Revision: 1607
http://sourceforge.net/p/opengtoolkit/svn/1607
Author: labviewer
Date: 2019-09-15 00:38:56 +0000 (Sun, 15 Sep 2019)
Log Message:
-----------
Add an endianess indication routine
Modified Paths:
--------------
trunk/lvzip/c_source/lvapi.c
trunk/lvzip/c_source/lvapi.h
trunk/lvzip/c_source/lvutil.c
Modified: trunk/lvzip/c_source/lvapi.c
===================================================================
--- trunk/lvzip/c_source/lvapi.c 2019-09-14 18:25:52 UTC (rev 1606)
+++ trunk/lvzip/c_source/lvapi.c 2019-09-15 00:38:56 UTC (rev 1607)
@@ -194,6 +194,17 @@
return version;
}
+
+LibAPI(uInt32) lvzlib_isLittleEndian(void)
+{
+#if BigEndian
+ return FALSE;
+#else
+ return TRUE;
+#endif
+}
+
+
/* exported zlib deflate and inflate functions */
LibAPI(int) lvzlib_compress(Bytef *dest, uInt32 *destLen,
const Bytef *source, uInt32 sourceLen, int level)
Modified: trunk/lvzip/c_source/lvapi.h
===================================================================
--- trunk/lvzip/c_source/lvapi.h 2019-09-14 18:25:52 UTC (rev 1606)
+++ trunk/lvzip/c_source/lvapi.h 2019-09-15 00:38:56 UTC (rev 1607)
@@ -31,6 +31,7 @@
#ifndef lvzip_lvapi_h
#define lvzip_lvapi_h
LibAPI(const char *) lvzlib_zlibVersion(void);
+LibAPI(uInt32) lvzlib_isLittleEndian(void);
/* exported zlib deflate and inflate functions */
LibAPI(int) lvzlib_compress(Bytef *dest, uInt32 *destLen, const Bytef *source, uInt32 sourceLen, int level);
LibAPI(int) lvzlib_uncompress(Bytef *dest, uInt32 *destLen, const Bytef *source, uInt32 sourceLen);
Modified: trunk/lvzip/c_source/lvutil.c
===================================================================
--- trunk/lvzip/c_source/lvutil.c 2019-09-14 18:25:52 UTC (rev 1606)
+++ trunk/lvzip/c_source/lvutil.c 2019-09-15 00:38:56 UTC (rev 1607)
@@ -1233,7 +1233,7 @@
}
else
{
- flags |= 0100000;
+ flags |= 010000;
}
return flags;
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <lab...@us...> - 2019-09-14 18:25:54
|
Revision: 1606
http://sourceforge.net/p/opengtoolkit/svn/1606
Author: labviewer
Date: 2019-09-14 18:25:52 +0000 (Sat, 14 Sep 2019)
Log Message:
-----------
Remove unused file flag constant
Modified Paths:
--------------
trunk/lvzip/c_source/lvutil.h
Modified: trunk/lvzip/c_source/lvutil.h
===================================================================
--- trunk/lvzip/c_source/lvutil.h 2019-09-14 18:24:05 UTC (rev 1605)
+++ trunk/lvzip/c_source/lvutil.h 2019-09-14 18:25:52 UTC (rev 1606)
@@ -676,7 +676,6 @@
#define kWinFileInfoOffline 0x00001000
#define kWinFileInfoNotIndexed 0x00002000
#define kWinFileInfoEncrypted 0x00004000
-#define kWinFileInfoVirtual 0x00010000
typedef struct { /* off */
uInt32 type; /* 0: handled by LabVIEW Type & Creator */
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <lab...@us...> - 2019-09-14 18:24:07
|
Revision: 1605
http://sourceforge.net/p/opengtoolkit/svn/1605
Author: labviewer
Date: 2019-09-14 18:24:05 +0000 (Sat, 14 Sep 2019)
Log Message:
-----------
Update library with begin of symlink support
Modified Paths:
--------------
trunk/lvzip/source/fileutil.llb/FILE Attributes.ctl
trunk/lvzip/source/fileutil.llb/FILE Attributes.vi
trunk/lvzip/source/fileutil.llb/FILE Create Link.vi
trunk/lvzip/source/fileutil.llb/FILE Read Link Target.vi
trunk/lvzip/source/fileutil.llb/FILE Resource File Info.vi
trunk/lvzip/source/fileutil.llb/FILE VI Tree.vi
trunk/lvzip/source/lvzip.llb/ZLIB Copy Raw File.vi
trunk/lvzip/source/lvzip.llb/ZLIB Delete Files From Archive.vi
trunk/lvzip/source/lvzip.llb/ZLIB Enumerate File Contents Old.vi
trunk/lvzip/source/lvzip.llb/ZLIB Enumerate File Contents.vi
trunk/lvzip/source/lvzip.llb/ZLIB Extract All Files To Dir.vi
trunk/lvzip/source/lvzip.llb/ZLIB Extract File.vi
trunk/lvzip/source/lvzip.llb/ZLIB Extract Stream.vi
trunk/lvzip/source/lvzip.llb/ZLIB Extract.vi
trunk/lvzip/source/lvzip.llb/ZLIB File Information.vi
trunk/lvzip/source/lvzip.llb/ZLIB Get Current File Info Old.vi
trunk/lvzip/source/lvzip.llb/ZLIB Get Current File Info.vi
trunk/lvzip/source/lvzip.llb/ZLIB Get File.vi
trunk/lvzip/source/lvzip.llb/ZLIB Go To Next File w Info.vi
trunk/lvzip/source/lvzip.llb/ZLIB Go To Next File.vi
trunk/lvzip/source/lvzip.llb/ZLIB Locate File w. Info.vi
trunk/lvzip/source/lvzip.llb/ZLIB Open Write File.vi
trunk/lvzip/source/lvzip.llb/ZLIB Store File.vi
trunk/lvzip/source/lvzip.llb/ZLIB Store Stream.vi
trunk/lvzip/source/lvzip.llb/ZLIB VI Tree.vi
Added Paths:
-----------
trunk/lvzip/source/lvzip.llb/ZLIB Entry Type.ctl
trunk/lvzip/source/lvzip.llb/ZLIB Store Link.vi
Modified: trunk/lvzip/source/fileutil.llb/FILE Attributes.ctl
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/fileutil.llb/FILE Attributes.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/fileutil.llb/FILE Create Link.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/fileutil.llb/FILE Read Link Target.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/fileutil.llb/FILE Resource File Info.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/fileutil.llb/FILE VI Tree.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Copy Raw File.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Delete Files From Archive.vi
===================================================================
(Binary files differ)
Added: trunk/lvzip/source/lvzip.llb/ZLIB Entry Type.ctl
===================================================================
(Binary files differ)
Index: trunk/lvzip/source/lvzip.llb/ZLIB Entry Type.ctl
===================================================================
--- trunk/lvzip/source/lvzip.llb/ZLIB Entry Type.ctl 2019-09-14 14:41:48 UTC (rev 1604)
+++ trunk/lvzip/source/lvzip.llb/ZLIB Entry Type.ctl 2019-09-14 18:24:05 UTC (rev 1605)
Property changes on: trunk/lvzip/source/lvzip.llb/ZLIB Entry Type.ctl
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Enumerate File Contents Old.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Enumerate File Contents.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Extract All Files To Dir.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Extract File.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Extract Stream.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Extract.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB File Information.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Get Current File Info Old.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Get Current File Info.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Get File.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Go To Next File w Info.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Go To Next File.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Locate File w. Info.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Open Write File.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Store File.vi
===================================================================
(Binary files differ)
Added: trunk/lvzip/source/lvzip.llb/ZLIB Store Link.vi
===================================================================
(Binary files differ)
Index: trunk/lvzip/source/lvzip.llb/ZLIB Store Link.vi
===================================================================
--- trunk/lvzip/source/lvzip.llb/ZLIB Store Link.vi 2019-09-14 14:41:48 UTC (rev 1604)
+++ trunk/lvzip/source/lvzip.llb/ZLIB Store Link.vi 2019-09-14 18:24:05 UTC (rev 1605)
Property changes on: trunk/lvzip/source/lvzip.llb/ZLIB Store Link.vi
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Store Stream.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB VI Tree.vi
===================================================================
(Binary files differ)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <lab...@us...> - 2019-09-14 14:41:50
|
Revision: 1604
http://sourceforge.net/p/opengtoolkit/svn/1604
Author: labviewer
Date: 2019-09-14 14:41:48 +0000 (Sat, 14 Sep 2019)
Log Message:
-----------
Update shared libraries for embedded platforms
Modified Paths:
--------------
trunk/lvzip/RT Images/LinuxRT_arm/liblvzlib.so
trunk/lvzip/RT Images/LinuxRT_x64/liblvzlib.so
trunk/lvzip/RT Images/Pharlap/lvzlib.dll
trunk/lvzip/RT Images/vxworks61/lvzlib.out
trunk/lvzip/RT Images/vxworks63/lvzlib.out
Modified: trunk/lvzip/RT Images/LinuxRT_arm/liblvzlib.so
===================================================================
(Binary files differ)
Modified: trunk/lvzip/RT Images/LinuxRT_x64/liblvzlib.so
===================================================================
(Binary files differ)
Modified: trunk/lvzip/RT Images/Pharlap/lvzlib.dll
===================================================================
(Binary files differ)
Modified: trunk/lvzip/RT Images/vxworks61/lvzlib.out
===================================================================
(Binary files differ)
Modified: trunk/lvzip/RT Images/vxworks63/lvzlib.out
===================================================================
(Binary files differ)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <lab...@us...> - 2019-09-14 14:30:16
|
Revision: 1603
http://sourceforge.net/p/opengtoolkit/svn/1603
Author: labviewer
Date: 2019-09-14 14:30:15 +0000 (Sat, 14 Sep 2019)
Log Message:
-----------
Fix error in previous makefile edit
Modified Paths:
--------------
trunk/lvzip/c_source/Makefile
Modified: trunk/lvzip/c_source/Makefile
===================================================================
--- trunk/lvzip/c_source/Makefile 2019-09-14 14:19:53 UTC (rev 1602)
+++ trunk/lvzip/c_source/Makefile 2019-09-14 14:30:15 UTC (rev 1603)
@@ -33,10 +33,10 @@
STATICLIB=lvzlib.a
SHAREDLIB=liblvzlib.so
+SHAREDLIBV=liblvzlib.so.4
+SHAREDLIBM=lvzlib.so
SHAREDLIB32=lvzlib.so
SHAREDLIB64=lvzlib64.so
-SHAREDLIBV=liblvzlib.so.4
-SHAREDLIBM=lvzlib.so
LIBS=$(STATICLIB) $(SHAREDLIBV)
AR=ar
@@ -175,7 +175,7 @@
placebo $(SHAREDLIBV) $(SHAREDLIB32) $(SHAREDLIB64): $(PIC_OBJS)
$(LDSHARED) $(SFLAGS) -shared -o $(ODIR)/$@ $(PIC_OBJS) $(LDSHAREDLIBC) $(LDFLAGS)
- rm -f $(ODIR)/$(SHAREDLIB) $(ODIR)/$(SHAREDLIBM) $(ODIR)/$(SHAREDLIBV)
+# rm -f $(ODIR)/$(SHAREDLIB) $(ODIR)/$(SHAREDLIBM) $(ODIR)/$(SHAREDLIBV)
# ln -s $(ODIR)/$@ $(ODIR)/$(SHAREDLIB)
# ln -s $(ODIR)/$@ $(ODIR)/$(SHAREDLIBM)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <lab...@us...> - 2019-09-14 14:19:55
|
Revision: 1602
http://sourceforge.net/p/opengtoolkit/svn/1602
Author: labviewer
Date: 2019-09-14 14:19:53 +0000 (Sat, 14 Sep 2019)
Log Message:
-----------
Extend the returned file info structure
Modified Paths:
--------------
trunk/lvzip/c_source/lvutil.c
trunk/lvzip/c_source/lvutil.h
Modified: trunk/lvzip/c_source/lvutil.c
===================================================================
--- trunk/lvzip/c_source/lvutil.c 2019-09-14 14:19:12 UTC (rev 1601)
+++ trunk/lvzip/c_source/lvutil.c 2019-09-14 14:19:53 UTC (rev 1602)
@@ -95,6 +95,7 @@
#include <dirent.h>
#include <fcntl.h>
#include <unistd.h>
+ #include <sys/stat.h>
#define ftruncate64 ftruncate
#ifdef HAVE_ICONV
#include <iconv.h>
@@ -102,10 +103,9 @@
#include <wchar.h>
#if VxWorks
#include <sys/types.h>
- #include <sys/stat.h>
#include <string.h>
#include <utime.h>
- #include <ioLib.h>
+// #include <ioLib.h>
#ifdef __GNUC__
#define ___unused __attribute__((unused))
#else
@@ -120,7 +120,7 @@
inline int link(const char* path1 ___unused, const char* path2 ___unused)
{
// VxWorks < 6.2 has no link() support
- errno = EACCES;
+ errno = ENOTSUP;
return -1;
}
@@ -127,7 +127,7 @@
inline int chmod(const char* _path ___unused, mode_t _mode ___unused)
{
// VxWorks < 6.2 has no chmod() support
- errno = EACCES;
+ errno = ENOTSUP;
return -1;
}
#endif
@@ -136,7 +136,7 @@
inline int symlink(const char* path1 ___unused, const char* path2 ___unused)
{
// vxWorks has no symlinks -> always return an error!
- errno = EACCES;
+ errno = ENOTSUP;
return -1;
}
@@ -217,19 +217,6 @@
return err;
}
-/* Convert a Macintosh UTDDateTime to a LabVIEW timestamp and vice versa */
-static void MacConvertFromLVTime(uInt32 time, UTCDateTime *mTime)
-{
- mTime->fraction = 0;
- mTime->lowSeconds = time;
- mTime->highSeconds = 0;
-}
-
-static void MacConvertToLVTime(UTCDateTime *mTime, uInt32 *time)
-{
- *time = mTime->lowSeconds;
-}
-
static MgErr OSErrToLVErr(OSErr err)
{
switch(err)
@@ -300,20 +287,6 @@
pt->u.f.fract = ((li.QuadPart - pt->u.f.val) * 0x100000000 / SECS_TO_FT_MULT) << 32;
}
-LibAPI(void) SystemTimeToATime(SYSTEMTIME *pst, ATime128 *pt)
-{
- FILETIME ft;
- SystemTimeToFileTime(pst, &ft);
- FileTimeToATime(&ft, pt);
-}
-
-LibAPI(void) ATimeToSystemTime(ATime128 *pt, SYSTEMTIME *pst)
-{
- FILETIME ft;
- ATimeToFileTime(pt, &ft);
- FileTimeToSystemTime(&ft, pst);
-}
-
static MgErr Win32ToLVFileErr(DWORD winErr)
{
switch (winErr)
@@ -453,6 +426,8 @@
#if Unix || MacOSX || defined(EMBEDDED)
#define LWStrPtr LStrPtr
+#define SStrBuf(s) (char*)LStrBuf(s)
+
/* wstr is filled with an 8 bit local encoded string from the path, which could be UTF8 on Linux and MacOSX systems */
static int32 MakePathDSString(Path path, LWStrPtr *lstr, size_t reserve)
{
@@ -1205,12 +1180,8 @@
LibAPI(MgErr) LVPath_HasResourceFork(Path path, LVBoolean *hasResFork, uInt32 *sizeLow, uInt32 *sizeHigh)
{
MgErr err = mgNoErr;
-#if Mac
-#if usesHFSPath
- FSRef ref;
-#else
+#if MacOSX
LStrHandle lstr = NULL;
-#endif
#else
Unused(path);
#endif
@@ -1221,32 +1192,10 @@
if (sizeHigh)
*sizeHigh = 0;
-#if Mac
-#if usesHFSPath // 32-Bit MacOSX
- err = FSMakePathRef(path, &ref);
+#if MacOSX
+ err = MakePathDSString(path, &lstr, 0);
if (!err)
{
- FSCatalogInfoBitmap whichInfo = kFSCatInfoNodeFlags | kFSCatInfoRsrcSizes;
- FSCatalogInfo catalogInfo;
-
- /* get nodeFlags and catalog info */
- err = OSErrToLVErr(FSGetCatalogInfo(&ref, whichInfo, &catalogInfo, NULL, NULL,NULL));
- if (!err && catalogInfo.nodeFlags & kFSNodeIsDirectoryMask)
- err = fIOErr;
- if (!err && catalogInfo.rsrcLogicalSize > 0)
- {
- if (hasResFork)
- *hasResFork = LV_TRUE;
- if (sizeLow)
- *sizeLow = Lo32(catalogInfo.rsrcLogicalSize);
- if (sizeHigh)
- *sizeHigh = Hi32(catalogInfo.rsrcLogicalSize);
- }
- }
-#else // 64-Bit MacOSX
- err = LVPath_ToText(path, &lstr);
- if (!err)
- {
ssize_t len = getxattr((const char)LStrBuf(*lstr), XATTR_RESOURCEFORK_NAME, NULL, 0, 0, O_NOFOLLOW);
if (len != -1)
{
@@ -1261,7 +1210,6 @@
DSDisposeHandle((UHandle)lstr);
}
#endif
-#endif
return err;
}
@@ -1399,6 +1347,8 @@
{
fileInfo->type = kUnknownFileType;
fileInfo->creator = kUnknownCreator;
+ fileInfo->uid = 0xFFFFFFFF;
+ fileInfo->gid = 0xFFFFFFFF;
FileTimeToATime(&fi.ftCreationTime, &fileInfo->cDate);
FileTimeToATime(&fi.ftLastWriteTime, &fileInfo->mDate);
FileTimeToATime(&fi.ftLastAccessTime, &fileInfo->aDate);
@@ -1405,6 +1355,7 @@
fileInfo->rfSize = 0;
fileInfo->winFlags = Lo16(fi.dwFileAttributes);
fileInfo->unixFlags = FlagsFromWindows(fileInfo->winFlags);
+ fileInfo->xtraFlags = 0;
if (fi.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
{
if (!FDepth(path))
@@ -1484,12 +1435,31 @@
UnixConvertFromATime(&fileInfo->cDate, &statbuf.st_ctim);
UnixConvertFromATime(&fileInfo->aDate, ×[0]);
UnixConvertFromATime(&fileInfo->mDate, ×[1]);
- if (utimensat(0, LStrBuf(lstr), times, AT_SYMLINK_NOFOLLOW))
+ if (utimensat(0, SStrBuf(lstr), times, AT_SYMLINK_NOFOLLOW))
#endif
err = UnixToLVFileErr();
- else if (chmod(LStrBuf(lstr), (statbuf.st_mode & 0170000) | (fileInfo->unixFlags & 07777)))
+
+#if !VxWorks
+ /*
+ * Changing the ownership probably won't succeed, unless we're root
+ * or POSIX_CHOWN_RESTRICTED is not set. Set uid/gid before setting
+ * the mode; current BSD behavior is to remove all setuid bits on
+ * chown. If chown fails, lose setuid/setgid bits.
+ */
+ else if (chown(SStrBuf(lstr), fileInfo->uid, fileInfo->gid))
+ {
+ if (errno != EPERM && errno != ENOTSUP)
+ err = UnixToLVFileErr();
+ fileInfo->unixFlags &= ~(S_ISUID | S_ISGID);
+ }
+#endif
+ if (!err && chmod(SStrBuf(lstr), (statbuf.st_mode & 0170000) | (fileInfo->unixFlags & 07777)) && errno != ENOTSUP)
err = UnixToLVFileErr();
+#if MacOSX
+ else if (chflags(SStrBuf(lstr), fileInfo->xtraFlags)
+ err = UnixToLVFileErr();
+#endif
}
else
{
@@ -1505,6 +1475,8 @@
fileInfo->type = kUnknownFileType;
fileInfo->creator = kUnknownCreator;
}
+ fileInfo->uid = statbuf.st_uid;
+ fileInfo->gid = statbuf.st_gid;
#if VxWorks
VxWorksConvertToATime(statbuf.st_ctime, &fileInfo->cDate);
VxWorksConvertToATime(statbuf.st_atime, &fileInfo->aDate);
@@ -1514,10 +1486,6 @@
UnixConvertToATime(&statbuf.st_mtim, &fileInfo->mDate);
UnixConvertToATime(&statbuf.st_atim, &fileInfo->aDate);
#endif
- fileInfo->rfSize = 0;
- fileInfo->size = statbuf.st_size;
- fileInfo->unixFlags = Lo16(statbuf.st_mode);
- fileInfo->winFlags = FlagsFromUnix(fileInfo->unixFlags);
if (S_ISDIR(statbuf.st_mode))
{
DIR *dirp;
@@ -1530,15 +1498,27 @@
count++;
closedir(dirp);
fileInfo->size = count - 2;
+ fileInfo->rfSize = 0;
}
else
{
+ fileInfo->size = statbuf.st_size;
#if MacOSX
ssize_t size = getxattr(LStrBuf(*lstr), XATTR_RESOURCEFORK_NAME, NULL, 0, 0, O_NOFOLLOW);
if (size > 0)
fileInfo->rfSize = (uInt64)size;
+ else
+#else
+ fileInfo->rfSize = 0;
#endif
}
+ fileInfo->unixFlags = Lo16(statbuf.st_mode);
+ fileInfo->winFlags = FlagsFromUnix(fileInfo->unixFlags);
+#if MacOSX
+ fileInfo->xtraFlags = statbuf.st_flags;
+#else
+ fileInfo->xtraFlags = 0;
+#endif
}
}
#endif
Modified: trunk/lvzip/c_source/lvutil.h
===================================================================
--- trunk/lvzip/c_source/lvutil.h 2019-09-14 14:19:12 UTC (rev 1601)
+++ trunk/lvzip/c_source/lvutil.h 2019-09-14 14:19:53 UTC (rev 1602)
@@ -678,17 +678,20 @@
#define kWinFileInfoEncrypted 0x00004000
#define kWinFileInfoVirtual 0x00010000
-typedef struct {
- uInt32 type; /* handled by LabVIEW Type & Creator */
- uInt32 creator; /* handled by LabVIEW Type & Creator */
- uInt64 size; /* file size or file count for directories */
- uInt64 rfSize; /* resource fork size, 0 on non MacOS platforms */
- ATime128 cDate; /* Creation date */
- ATime128 mDate; /* Modification date */
- ATime128 aDate; /* ast access date */
- uInt16 winFlags; /* Windows compatible flags */
- uInt32 unixFlags; /* Unix compatible flags */
-} LVFileInfo;
+typedef struct { /* off */
+ uInt32 type; /* 0: handled by LabVIEW Type & Creator */
+ uInt32 creator; /* 4: handled by LabVIEW Type & Creator */
+ uInt32 uid; /* 8: Unix user id */
+ uInt32 gid; /* 12: Unix group id */
+ uInt64 size; /* 16: file size or file count for directories */
+ uInt64 rfSize; /* 24: resource fork size, 0 on non MacOS platforms */
+ ATime128 cDate; /* 32: Creation date */
+ ATime128 mDate; /* 48: Modification date */
+ ATime128 aDate; /* 64: ast access date */
+ uInt16 winFlags; /* 80: Windows compatible flags */
+ uInt16 unixFlags; /* 82: Unix compatible flags */
+ uInt32 xtraFlags; /* 84: MacOSX extra file flags */
+} LVFileInfo; /* 88: Total length */
/* Retrieve file information from the path */
LibAPI(MgErr) LVPath_FileInfo(Path path, uInt8 write, LVFileInfo *fileInfo);
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <lab...@us...> - 2019-09-14 14:19:14
|
Revision: 1601
http://sourceforge.net/p/opengtoolkit/svn/1601
Author: labviewer
Date: 2019-09-14 14:19:12 +0000 (Sat, 14 Sep 2019)
Log Message:
-----------
Cleanup various makefiles somewhat
Modified Paths:
--------------
trunk/lvzip/c_source/Makefile
trunk/lvzip/c_source/Makefile.vxworks
trunk/lvzip/c_source/zlibvc.vcproj
Removed Paths:
-------------
trunk/lvzip/c_source/Makefile.x64
Modified: trunk/lvzip/c_source/Makefile
===================================================================
--- trunk/lvzip/c_source/Makefile 2019-09-13 16:17:41 UTC (rev 1600)
+++ trunk/lvzip/c_source/Makefile 2019-09-14 14:19:12 UTC (rev 1601)
@@ -33,6 +33,8 @@
STATICLIB=lvzlib.a
SHAREDLIB=liblvzlib.so
+SHAREDLIB32=lvzlib.so
+SHAREDLIB64=lvzlib64.so
SHAREDLIBV=liblvzlib.so.4
SHAREDLIBM=lvzlib.so
LIBS=$(STATICLIB) $(SHAREDLIBV)
@@ -81,10 +83,10 @@
all: static all64
linux32: clean
- $(MAKE) $(SHAREDLIBV) ODIR=./Linux_x86 CC_ARCH_SPEC="-m32"
+ $(MAKE) $(SHAREDLIB32) ODIR=./Linux_x86 CC_ARCH_SPEC="-m32"
linux64: clean
- $(MAKE) $(SHAREDLIBV) ODIR=./Linux_x64 CC_ARCH_SPEC="-m64"
+ $(MAKE) $(SHAREDLIB64) ODIR=./Linux_x64 CC_ARCH_SPEC="-m64"
static: example$(EXE) minigzip$(EXE)
@@ -171,9 +173,9 @@
-@mkdir $(ODIR)/bzip2 2>/dev/null || test -d $(ODIR)/bzip2
$(CC) $(SFLAGS) -DPIC -c -o $(ODIR)/$*.lo $<
-placebo $(SHAREDLIBV): $(PIC_OBJS)
+placebo $(SHAREDLIBV) $(SHAREDLIB32) $(SHAREDLIB64): $(PIC_OBJS)
$(LDSHARED) $(SFLAGS) -shared -o $(ODIR)/$@ $(PIC_OBJS) $(LDSHAREDLIBC) $(LDFLAGS)
- rm -f $(ODIR)/$(SHAREDLIB) $(ODIR)/$(SHAREDLIBM)
+ rm -f $(ODIR)/$(SHAREDLIB) $(ODIR)/$(SHAREDLIBM) $(ODIR)/$(SHAREDLIBV)
# ln -s $(ODIR)/$@ $(ODIR)/$(SHAREDLIB)
# ln -s $(ODIR)/$@ $(ODIR)/$(SHAREDLIBM)
Modified: trunk/lvzip/c_source/Makefile.vxworks
===================================================================
--- trunk/lvzip/c_source/Makefile.vxworks 2019-09-13 16:17:41 UTC (rev 1600)
+++ trunk/lvzip/c_source/Makefile.vxworks 2019-09-14 14:19:12 UTC (rev 1601)
@@ -5,10 +5,10 @@
ADDED_CFLAGS = -DHAVE_AES -DHAVE_BZIP2 -DNO_BZ_STDIO
ifeq ($(DEBUG_MODE),1)
-OBJ_DIR := PPC603gnu_DEBUG
+OBJ_DIR := $(OBJ_BASE)/Debug
CFLAGS = -g -mlongcall
else
-OBJ_DIR := PPC603gnu
+OBJ_DIR := $(OBJ_BASE)/Release
CFLAGS = -Os -fstrength-reduce -fno-builtin -fno-strict-aliasing -mlongcall
endif
Deleted: trunk/lvzip/c_source/Makefile.x64
===================================================================
--- trunk/lvzip/c_source/Makefile.x64 2019-09-13 16:17:41 UTC (rev 1600)
+++ trunk/lvzip/c_source/Makefile.x64 2019-09-14 14:19:12 UTC (rev 1601)
@@ -1,87 +0,0 @@
-# Nmake macros for building makefile
-!include <win32.mak>
-
-PROJ = LVZLIB
-
-all: $(OUTDIR) $(OUTDIR)\lvzlib.dll
-
-"$(OUTDIR)" :
- if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
-
-#--------------------------------------------------------------------#
-
-SOURCES=adler32.c \
- compress.c \
- crc32.c \
- deflate.c \
- gzclose.c \
- gzlib.c \
- gzread.c \
- gzwrite.c \
- infback.c \
- inffast.c \
- inflate.c \
- inftrees.c \
- ioapi.c \
- iowin.c \
- iomem.c \
- lvapi.c \
- lvutil.c \
- mztools.c \
- trees.c \
- uncompr.c \
- unzip.c \
- zip.c \
- zutil.c
-
-OBJS=$(OUTDIR)\adler32.obj \
- $(OUTDIR)\compress.obj \
- $(OUTDIR)\crc32.obj \
- $(OUTDIR)\deflate.obj \
- $(OUTDIR)\gzclose.obj \
- $(OUTDIR)\gzlib.obj \
- $(OUTDIR)\gzread.obj \
- $(OUTDIR)\gzwrite.obj \
- $(OUTDIR)\infback.obj \
- $(OUTDIR)\inffast.obj \
- $(OUTDIR)\inflate.obj \
- $(OUTDIR)\inftrees.obj \
- $(OUTDIR)\ioapi.obj \
- $(OUTDIR)\iowin.obj \
- $(OUTDIR)\iomem.obj \
- $(OUTDIR)\lvapi.obj \
- $(OUTDIR)\lvutil.obj \
- $(OUTDIR)\mztools.obj \
- $(OUTDIR)\trees.obj \
- $(OUTDIR)\uncompr.obj \
- $(OUTDIR)\unzip.obj \
- $(OUTDIR)\zip.obj \
- $(OUTDIR)\zutil.obj
-
-ELIBS=user32.lib kernel32.lib labview.lib
-
-# Build rules for resource files
-
-# Update the resources
-
-$(OUTDIR)\lvzlib.res: zlib.rc
- $(rc) $(rcflags) $(rcvars) /fo $(OUTDIR)\lvzlib.res zlib.rc
-
-# Compile the sources
-
-.c{$(OUTDIR)}.obj:
- $(cc) $(cdebug) $(cflags) $(cvarsdll) /Fp"$(OUTDIR)\\" /Fo"$(OUTDIR)\\" /Fd"$(OUTDIR)\\" $**
-
-# Update the import library
-
-$(OUTDIR)\lvzlib.exp: $(OBJS) lvzlib.def
- $(implib) -machine:$(CPU) -def:lvzlib.def -out:$(OUTDIR)\lvzlib.lib $(OBJS)
-
-# Update the dynamic link library
-
-$(OUTDIR)\lvzlib.dll: $(OBJS) $(OUTDIR)\lvzlib.res $(OUTDIR)\lvzlib.exp lvzlib.def
- $(link) $(ldebug) $(dlllflags) $(conlibsdll) /MACHINE:$(CPU) -out:$(OUTDIR)\lvzlib.dll \
- $(OBJS) $(ELIBS) $(OUTDIR)\lvzlib.exp $(OUTDIR)\lvzlib.res
-
-clean:
- $(CLEANUP)
\ No newline at end of file
Modified: trunk/lvzip/c_source/zlibvc.vcproj
===================================================================
--- trunk/lvzip/c_source/zlibvc.vcproj 2019-09-13 16:17:41 UTC (rev 1600)
+++ trunk/lvzip/c_source/zlibvc.vcproj 2019-09-14 14:19:12 UTC (rev 1601)
@@ -519,7 +519,7 @@
Name="VCLinkerTool"
IgnoreImportLibrary="true"
AdditionalDependencies="labview64.lib"
- OutputFile="$(OutDir)\lvzlib.dll"
+ OutputFile="$(OutDir)\lvzlib64.dll"
LinkIncremental="1"
SuppressStartupBanner="true"
AdditionalLibraryDirectories="../../cintools"
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <lab...@us...> - 2019-09-13 16:17:43
|
Revision: 1600
http://sourceforge.net/p/opengtoolkit/svn/1600
Author: labviewer
Date: 2019-09-13 16:17:41 +0000 (Fri, 13 Sep 2019)
Log Message:
-----------
Redesign of file attribute and symlink handling
Modified Paths:
--------------
trunk/lvzip/source/fileutil.llb/FILE Open File Refnum.vi
trunk/lvzip/source/fileutil.llb/FILE Resource File Info.vi
trunk/lvzip/source/fileutil.llb/FILE VI Tree.vi
trunk/lvzip/source/lvzip.llb/ZLIB File Information.vi
trunk/lvzip/source/lvzip.llb/ZLIB Get File.vi
trunk/lvzip/source/lvzip.llb/ZLIB Store File.vi
trunk/lvzip/source/lvzip.llb/ZLIB VI Tree.vi
trunk/lvzip/source/macbin.llb/MACBIN Create Header.vi
trunk/lvzip/source/macbin.llb/MACBIN Decode MacBinary.vi
trunk/lvzip/source/macbin.llb/MACBIN Encode MacBinary.vi
trunk/lvzip/source/macbin.llb/MACBIN Read Header.vi
trunk/lvzip/source/macbin.llb/MACBIN Resource File Info.vi
trunk/lvzip/source/macbin.llb/MACBIN VI Tree.vi
Added Paths:
-----------
trunk/lvzip/source/fileutil.llb/FILE Attributes.ctl
trunk/lvzip/source/fileutil.llb/FILE Attributes.vi
Added: trunk/lvzip/source/fileutil.llb/FILE Attributes.ctl
===================================================================
(Binary files differ)
Index: trunk/lvzip/source/fileutil.llb/FILE Attributes.ctl
===================================================================
--- trunk/lvzip/source/fileutil.llb/FILE Attributes.ctl 2019-09-13 15:42:32 UTC (rev 1599)
+++ trunk/lvzip/source/fileutil.llb/FILE Attributes.ctl 2019-09-13 16:17:41 UTC (rev 1600)
Property changes on: trunk/lvzip/source/fileutil.llb/FILE Attributes.ctl
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Added: trunk/lvzip/source/fileutil.llb/FILE Attributes.vi
===================================================================
(Binary files differ)
Index: trunk/lvzip/source/fileutil.llb/FILE Attributes.vi
===================================================================
--- trunk/lvzip/source/fileutil.llb/FILE Attributes.vi 2019-09-13 15:42:32 UTC (rev 1599)
+++ trunk/lvzip/source/fileutil.llb/FILE Attributes.vi 2019-09-13 16:17:41 UTC (rev 1600)
Property changes on: trunk/lvzip/source/fileutil.llb/FILE Attributes.vi
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Modified: trunk/lvzip/source/fileutil.llb/FILE Open File Refnum.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/fileutil.llb/FILE Resource File Info.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/fileutil.llb/FILE VI Tree.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB File Information.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Get File.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Store File.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB VI Tree.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/macbin.llb/MACBIN Create Header.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/macbin.llb/MACBIN Decode MacBinary.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/macbin.llb/MACBIN Encode MacBinary.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/macbin.llb/MACBIN Read Header.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/macbin.llb/MACBIN Resource File Info.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/macbin.llb/MACBIN VI Tree.vi
===================================================================
(Binary files differ)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <lab...@us...> - 2019-09-03 21:16:37
|
Revision: 1598
http://sourceforge.net/p/opengtoolkit/svn/1598
Author: labviewer
Date: 2019-09-03 21:16:35 +0000 (Tue, 03 Sep 2019)
Log Message:
-----------
Updated to version 4.2.0
Modified Paths:
--------------
trunk/lvzip/PostInstall.vi
trunk/lvzip/build_support/lvzip.rev
trunk/lvzip/lvzip RT Images.iss
trunk/lvzip/lvzip.ogbld
trunk/lvzip/lvzip.ogpb
Modified: trunk/lvzip/PostInstall.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/build_support/lvzip.rev
===================================================================
--- trunk/lvzip/build_support/lvzip.rev 2019-09-03 21:03:02 UTC (rev 1597)
+++ trunk/lvzip/build_support/lvzip.rev 2019-09-03 21:16:35 UTC (rev 1598)
@@ -1,8 +1,8 @@
[lvzip.ogbld]
-Version=2.5.2
-Build_Number=34
-Build_Date="9/5/2009 12:09:58 PM"
+Version=4.2.0
+Build_Number=38
+Build_Date="30-8-2019 00:38:59"
Status=OK
-Warnings=1
-Log_File=/D/Projects/OpenG/opengtoolkit/SVN_Folders/lvzip/built/lvzip.log
+Warnings=0
+Log_File="/P/Work/OpenG/Openg Toolkit/lvzip/built/lvzip.log"
Modified: trunk/lvzip/lvzip RT Images.iss
===================================================================
--- trunk/lvzip/lvzip RT Images.iss 2019-09-03 21:03:02 UTC (rev 1597)
+++ trunk/lvzip/lvzip RT Images.iss 2019-09-03 21:16:35 UTC (rev 1598)
@@ -3,12 +3,14 @@
[Setup]
AppName=OpenG ZIP Library for NI RT controllers
-AppVersion=4.1
-DefaultDirName={reg:HKLM32\Software\National Instruments\RT Images,Path|{pf32}\National Instruments\RT Images}\OpenG ZIP Tools\4.1.0
+AppVersion=4.2
+DefaultDirName={reg:HKLM32\Software\National Instruments\RT Images,Path|{pf32}\National Instruments\RT Images}\OpenG ZIP Tools\4.2.0
DisableDirPage=yes
SourceDir=RT Images
OutputDir=..\built\RT Images
PrivilegesRequired=admin
+UsePreviousAppDir=no
+OutputBaseFilename=ogsetup
[Files]
Source: "*.*"; DestDir: "{app}"; Flags: recursesubdirs
Modified: trunk/lvzip/lvzip.ogbld
===================================================================
--- trunk/lvzip/lvzip.ogbld 2019-09-03 21:03:02 UTC (rev 1597)
+++ trunk/lvzip/lvzip.ogbld 2019-09-03 21:16:35 UTC (rev 1598)
@@ -87,4 +87,14 @@
Save Level=0
Default Destination=FALSE
Apply New Password=""
+Namespace=""
+
+[Destination 3]
+Source Dir=fileutil.llb
+Target Dir=fileutil.llb
+Convert Target to LLB=FALSE
+Convert Target to EXE=FALSE
+Save Level=0
+Default Destination=FALSE
+Apply New Password=""
Namespace=""
\ No newline at end of file
Modified: trunk/lvzip/lvzip.ogpb
===================================================================
--- trunk/lvzip/lvzip.ogpb 2019-09-03 21:03:02 UTC (rev 1597)
+++ trunk/lvzip/lvzip.ogpb 2019-09-03 21:16:35 UTC (rev 1598)
@@ -3,7 +3,7 @@
[Package Name]
Name=oglib_lvzip
-Version=4.1.0
+Version=4.2.0
Release=1
Display Name="OpenG ZIP Library"
@@ -11,12 +11,12 @@
Description="The lvzip package contains several routines for operating on zip files.\0D\0A"
Summary="OpenG Zip Tools"
License="BSD (VIs), LGPL (Shared Library)"
-Copyright="1995-2014 Mark Adler, Jean-loup Gailly\0A1998-2014 Gilles Vollant\0A2002 - 2009 Christophe Salzmann, Jim Kring\0A2002 - 2015 Rolf Kalbermatter"
+Copyright="1995-2018 Mark Adler, Jean-loup Gailly\0A1998-2014 Gilles Vollant\0A2002 - 2009 Christophe Salzmann, Jim Kring\0A2002 - 2019 Rolf Kalbermatter"
Distribution="OpenG Toolkit"
Vendor=OpenG.org
URL=http://wiki.openg.org/oglib_lvzip
Packager="Jim Kring <ji...@ji...>"
-Release Notes="Version 4.1: Updated to zlib 1.2.8 and added support for new cRIO targets\0AVersion 4.0: New palette menu structure\0AVersion 2.5.2: Adds support for the new palette locations of OpenG 4.x packages and removes dependency on ogrsc_dynamicpalette package.\0D\0AVersion 2.5.1: Fixes issue with broken VIs in LabVIEW 2009 due to calling (now) private config utilities.\0D\0AVersion 2.5: Changes license of LabVIEW sources from LGPL to BSD, Adds Memory Stream VIs to the palettes, Optimizes ZLIB Extract All Files to Dir, Fixes potential problem where error such as out of disk on finishing to add a file into an archive might get lost meaning that a corrupted archive could result without the user being informed about it, Fixes issue preventing adding files specified by UNC network path to zip archive.\0D\0AVersion 2.4 adds support for direct memory stream handling.\0D\0AVersion 2.3 adds support for transparent Mac Resource file handling through MacBinary encoding.\0D\0AVersion 2.2 adds support for appending files to an existing archive, deleting files from an archive and password support for adding and extracting files."
+Release Notes="Version 4.2: Updated to zlib 1.2.11 and minizip 1.2 - June 14, 2019 and more 64-bit support\0AVersion 4.1: Updated to zlib 1.2.8 and added support for new cRIO targets\0AVersion 4.0: New palette menu structure\0AVersion 2.5.2: Adds support for the new palette locations of OpenG 4.x packages and removes dependency on ogrsc_dynamicpalette package.\0D\0AVersion 2.5.1: Fixes issue with broken VIs in LabVIEW 2009 due to calling (now) private config utilities.\0D\0AVersion 2.5: Changes license of LabVIEW sources from LGPL to BSD, Adds Memory Stream VIs to the palettes, Optimizes ZLIB Extract All Files to Dir, Fixes potential problem where error such as out of disk on finishing to add a file into an archive might get lost meaning that a corrupted archive could result without the user being informed about it, Fixes issue preventing adding files specified by UNC network path to zip archive.\0D\0AVersion 2.4 adds support for direct memory stream handling.\0D\0AVersion 2.3 adds support for transparent Mac Resource file handling through MacBinary encoding.\0D\0AVersion 2.2 adds support for appending files to an existing archive, deleting files from an archive and password support for adding and extracting files."
Demo=FALSE
System Package=FALSE
Sub Package=FALSE
@@ -49,7 +49,7 @@
Conflicts=""
[Files]
-Num File Groups=11
+Num File Groups=12
Source Dir=""
Target Dir=""
Passwords.<size(s)>=0
@@ -67,7 +67,6 @@
Replace Mode=Always
Num Files=1
File 0=*.mnu
-Locked 0=-1
[File Group 1]
Source Dir=source
@@ -78,7 +77,6 @@
Replace Mode=Always
Num Files=1
File 0=readme.txt
-Locked 0=-1
[File Group 2]
Source Dir=built/lvzip/lvzip.llb
@@ -89,9 +87,7 @@
Replace Mode=Always
Num Files=2
File 0=*.vi
-Locked 0=-1
File 1=*.ctl
-Locked 1=-1
[File Group 3]
Source Dir=built/lvzip/macbin.llb
@@ -102,11 +98,20 @@
Replace Mode=Always
Num Files=2
File 0=*.vi
-Locked 0=-1
File 1=*.ctl
-Locked 1=-1
[File Group 4]
+Source Dir=built/lvzip/fileutil.llb
+DirMode=0
+NameMode=0
+PPFix=""
+Target Dir=<OpenG.lib>/lvzip/fileutil.llb
+Replace Mode=Always
+Num Files=2
+File 0=*.vi
+File 1=*.ctl
+
+[File Group 5]
Source Dir=source
DirMode=0
NameMode=0
@@ -116,9 +121,8 @@
Exclusive_OS="Windows NT,Windows 9x,Windows x64"
Num Files=1
File 0=*.dll
-Locked 0=-1
-[File Group 5]
+[File Group 6]
Source Dir=source
DirMode=0
NameMode=0
@@ -128,9 +132,8 @@
Exclusive_OS="Linux,Linux x64"
Num Files=1
File 0=*.so
-Locked 0=-1
-[File Group 6]
+[File Group 7]
Source Dir=source
DirMode=0
NameMode=0
@@ -140,9 +143,8 @@
Exclusive_OS="Mac OS>=10"
Num Files=1
File 0=lvzlib.framework.zip
-Locked 0=-1
-[File Group 7]
+[File Group 8]
Source Dir="built/RT Images"
DirMode=0
NameMode=0
@@ -151,10 +153,9 @@
Replace Mode="If Newer"
Exclusive_OS="Windows NT,Windows 9x"
Num Files=1
-File 0=setup.exe
-Locked 0=-1
+File 0=ogsetup.exe
-[File Group 8]
+[File Group 9]
Source Dir="Dynamic Palette MNUs"
DirMode=0
NameMode=0
@@ -163,9 +164,8 @@
Replace Mode=Always
Num Files=1
File 0=oglib_lvzip.mnu
-Locked 0=-1
-[File Group 9]
+[File Group 10]
Source Dir="Dynamic Palette MNUs"
DirMode=0
NameMode=0
@@ -174,9 +174,8 @@
Replace Mode=Always
Num Files=1
File 0=oglib_lvzip.mnu
-Locked 0=-1
-[File Group 10]
+[File Group 11]
Source Dir="Dynamic Palette MNUs"
DirMode=0
NameMode=0
@@ -185,5 +184,4 @@
Replace Mode=Always
Num Files=1
File 0=oglib_lvzip.mnu
-Locked 0=-1
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <lab...@us...> - 2019-09-03 21:03:04
|
Revision: 1597
http://sourceforge.net/p/opengtoolkit/svn/1597
Author: labviewer
Date: 2019-09-03 21:03:02 +0000 (Tue, 03 Sep 2019)
Log Message:
-----------
Latest Update to latest state from the nmoinvaz/minizip ver 1.2 github repository
Modified Paths:
--------------
trunk/lvzip/RT Images/LinuxRT_arm/liblvzlib.so
trunk/lvzip/RT Images/LinuxRT_x64/liblvzlib.so
trunk/lvzip/RT Images/Pharlap/lvzlib.dll
trunk/lvzip/RT Images/vxworks61/lvzlib.out
trunk/lvzip/RT Images/vxworks63/lvzlib.out
trunk/lvzip/source/lvzlib.dll
trunk/lvzip/source/lvzlib.framework.zip
trunk/lvzip/source/lvzlib.so
trunk/lvzip/source/lvzlib64.dll
trunk/lvzip/source/lvzlib64.so
Modified: trunk/lvzip/RT Images/LinuxRT_arm/liblvzlib.so
===================================================================
(Binary files differ)
Modified: trunk/lvzip/RT Images/LinuxRT_x64/liblvzlib.so
===================================================================
(Binary files differ)
Modified: trunk/lvzip/RT Images/Pharlap/lvzlib.dll
===================================================================
(Binary files differ)
Modified: trunk/lvzip/RT Images/vxworks61/lvzlib.out
===================================================================
(Binary files differ)
Modified: trunk/lvzip/RT Images/vxworks63/lvzlib.out
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzlib.dll
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzlib.framework.zip
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzlib.so
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzlib64.dll
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzlib64.so
===================================================================
(Binary files differ)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <lab...@us...> - 2019-09-02 20:05:58
|
Revision: 1596
http://sourceforge.net/p/opengtoolkit/svn/1596
Author: labviewer
Date: 2019-09-02 20:05:56 +0000 (Mon, 02 Sep 2019)
Log Message:
-----------
Update to latest state from the nmoinvaz/minizip ver 1.2 github repository
Modified Paths:
--------------
trunk/lvzip/c_source/ioapi.h
trunk/lvzip/c_source/unzip.c
trunk/lvzip/c_source/zip.c
Modified: trunk/lvzip/c_source/ioapi.h
===================================================================
--- trunk/lvzip/c_source/ioapi.h 2019-09-01 16:39:24 UTC (rev 1595)
+++ trunk/lvzip/c_source/ioapi.h 2019-09-02 20:05:56 UTC (rev 1596)
@@ -42,13 +42,8 @@
# define ftello64 ftell
# define fseeko64 fseek
#else
-# if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__DragonFly__) || defined(__OpenBSD__) || defined(__APPLE__) || defined(__ANDROID__)
+# if defined(_MSC_VER)
# define fopen64 fopen
-# define ftello64 ftello
-# define fseeko64 fseeko
-# endif
-# ifdef _MSC_VER
-# define fopen64 fopen
# if (_MSC_VER >= 1400) && (!(defined(NO_MSCVER_FILE64_FUNC)))
# define ftello64 _ftelli64
# define fseeko64 _fseeki64
@@ -56,6 +51,10 @@
# define ftello64 ftell
# define fseeko64 fseek
# endif
+# else
+# define fopen64 fopen
+# define ftello64 ftello
+# define fseeko64 fseeko
# endif
#endif
Modified: trunk/lvzip/c_source/unzip.c
===================================================================
--- trunk/lvzip/c_source/unzip.c 2019-09-01 16:39:24 UTC (rev 1595)
+++ trunk/lvzip/c_source/unzip.c 2019-09-02 20:05:56 UTC (rev 1596)
@@ -1251,8 +1251,7 @@
#endif
{
int i;
- int8_t actual;
- uint8_t expected;
+ uint8_t actual, expected;
s->pcrc_32_tab = (const z_crc_t*)get_crc_table();
init_keys(password, s->keys, s->pcrc_32_tab);
@@ -1268,7 +1267,7 @@
s->cur_file_info.crc >> 24);
actual = (uint8_t)source[11];
- if (expected != actual) {
+ if ((actual != 0) && (expected != actual)) {
return UNZ_BADPASSWORD;
}
Modified: trunk/lvzip/c_source/zip.c
===================================================================
--- trunk/lvzip/c_source/zip.c 2019-09-01 16:39:24 UTC (rev 1595)
+++ trunk/lvzip/c_source/zip.c 2019-09-02 20:05:56 UTC (rev 1596)
@@ -1520,9 +1520,8 @@
if ((zi->ci.compression_method == Z_DEFLATED) && (!zi->ci.raw))
{
+ uint32_t total_out_before = (uint32_t)zi->ci.stream.total_out;
#ifdef HAVE_APPLE_COMPRESSION
- uLong total_out_before = zi->ci.stream.total_out;
-
zi->ci.astream.src_ptr = zi->ci.stream.next_in;
zi->ci.astream.src_size = zi->ci.stream.avail_in;
zi->ci.astream.dst_ptr = zi->ci.stream.next_out;
@@ -1533,7 +1532,7 @@
status = compression_stream_process(&zi->ci.astream, flags);
- uLong total_out_after = len - zi->ci.astream.src_size;
+ uint32_t total_out_after = len - zi->ci.astream.src_size;
zi->ci.stream.next_in = zi->ci.astream.src_ptr;
zi->ci.stream.avail_in = zi->ci.astream.src_size;
@@ -1546,7 +1545,6 @@
if (status == COMPRESSION_STATUS_ERROR)
err = ZIP_INTERNALERROR;
#else
- uint32_t total_out_before = (uint32_t)zi->ci.stream.total_out;
err = deflate(&zi->ci.stream, Z_NO_FLUSH);
zi->ci.pos_in_buffered_data += (uint32_t)(zi->ci.stream.total_out - total_out_before);
#endif
@@ -1908,7 +1906,7 @@
pos = centraldir_pos_inzip - zi->add_position_when_writting_offset;
/* Write the ZIP64 central directory header */
- if (pos >= UINT32_MAX || zi->number_entry > UINT32_MAX)
+ if (pos >= UINT32_MAX || zi->number_entry > UINT16_MAX)
{
uint64_t zip64_eocd_pos_inzip = ZTELL64(zi->z_filefunc, zi->filestream);
uint32_t zip64_datasize = 44;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <lab...@us...> - 2019-09-01 16:39:26
|
Revision: 1595
http://sourceforge.net/p/opengtoolkit/svn/1595
Author: labviewer
Date: 2019-09-01 16:39:24 +0000 (Sun, 01 Sep 2019)
Log Message:
-----------
Update Macintosh framework
Modified Paths:
--------------
trunk/lvzip/source/lvzlib.framework.zip
Modified: trunk/lvzip/source/lvzlib.framework.zip
===================================================================
(Binary files differ)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <lab...@us...> - 2019-09-01 16:38:49
|
Revision: 1594
http://sourceforge.net/p/opengtoolkit/svn/1594
Author: labviewer
Date: 2019-09-01 16:38:47 +0000 (Sun, 01 Sep 2019)
Log Message:
-----------
Update Macintosh framework
Modified Paths:
--------------
trunk/lvzip/c_source/lvutil.c
trunk/lvzip/c_source/lvzip.xcodeproj/project.pbxproj
Modified: trunk/lvzip/c_source/lvutil.c
===================================================================
--- trunk/lvzip/c_source/lvutil.c 2019-08-31 22:52:12 UTC (rev 1593)
+++ trunk/lvzip/c_source/lvutil.c 2019-09-01 16:38:47 UTC (rev 1594)
@@ -1629,7 +1629,7 @@
LStrHandle hfsPath = NULL;
/* Convert the posix path to an HFS path */
err = ConvertFromPosixPath(str, len, CP_ACP, &hfsPath, CP_ACP, '?', NULL, isDir);
- if (!err && hsfPath)
+ if (!err && hfsPath)
{
err = FTextToPath(LStrBuf(*hfsPath), LStrLen(*hfsPath), path);
}
Modified: trunk/lvzip/c_source/lvzip.xcodeproj/project.pbxproj
===================================================================
--- trunk/lvzip/c_source/lvzip.xcodeproj/project.pbxproj 2019-08-31 22:52:12 UTC (rev 1593)
+++ trunk/lvzip/c_source/lvzip.xcodeproj/project.pbxproj 2019-09-01 16:38:47 UTC (rev 1594)
@@ -51,6 +51,7 @@
883262811B163FAF003BB2F4 /* aestab.h in Headers */ = {isa = PBXBuildFile; fileRef = 8832626C1B163FAF003BB2F4 /* aestab.h */; };
883262821B163FAF003BB2F4 /* brg_endian.h in Headers */ = {isa = PBXBuildFile; fileRef = 8832626D1B163FAF003BB2F4 /* brg_endian.h */; };
883262831B163FAF003BB2F4 /* brg_types.h in Headers */ = {isa = PBXBuildFile; fileRef = 8832626E1B163FAF003BB2F4 /* brg_types.h */; };
+ 883262851B163FAF003BB2F4 /* entropy.h in Headers */ = {isa = PBXBuildFile; fileRef = 883262701B163FAF003BB2F4 /* entropy.h */; };
883262871B163FAF003BB2F4 /* fileenc.h in Headers */ = {isa = PBXBuildFile; fileRef = 883262721B163FAF003BB2F4 /* fileenc.h */; };
883262881B163FAF003BB2F4 /* hmac.c in Sources */ = {isa = PBXBuildFile; fileRef = 883262731B163FAF003BB2F4 /* hmac.c */; };
883262891B163FAF003BB2F4 /* hmac.h in Headers */ = {isa = PBXBuildFile; fileRef = 883262741B163FAF003BB2F4 /* hmac.h */; };
@@ -124,6 +125,7 @@
8832626C1B163FAF003BB2F4 /* aestab.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = aestab.h; path = aes/aestab.h; sourceTree = "<group>"; };
8832626D1B163FAF003BB2F4 /* brg_endian.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = brg_endian.h; path = aes/brg_endian.h; sourceTree = "<group>"; };
8832626E1B163FAF003BB2F4 /* brg_types.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = brg_types.h; path = aes/brg_types.h; sourceTree = "<group>"; };
+ 883262701B163FAF003BB2F4 /* entropy.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = entropy.h; path = aes/entropy.h; sourceTree = "<group>"; };
883262721B163FAF003BB2F4 /* fileenc.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = fileenc.h; path = aes/fileenc.h; sourceTree = "<group>"; };
883262731B163FAF003BB2F4 /* hmac.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = hmac.c; path = aes/hmac.c; sourceTree = "<group>"; };
883262741B163FAF003BB2F4 /* hmac.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = hmac.h; path = aes/hmac.h; sourceTree = "<group>"; };
@@ -253,6 +255,7 @@
8832626C1B163FAF003BB2F4 /* aestab.h */,
8832626D1B163FAF003BB2F4 /* brg_endian.h */,
8832626E1B163FAF003BB2F4 /* brg_types.h */,
+ 883262701B163FAF003BB2F4 /* entropy.h */,
883262721B163FAF003BB2F4 /* fileenc.h */,
883262731B163FAF003BB2F4 /* hmac.c */,
883262741B163FAF003BB2F4 /* hmac.h */,
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <lab...@us...> - 2019-08-31 22:52:14
|
Revision: 1593
http://sourceforge.net/p/opengtoolkit/svn/1593
Author: labviewer
Date: 2019-08-31 22:52:12 +0000 (Sat, 31 Aug 2019)
Log Message:
-----------
Add two new files
Added Paths:
-----------
trunk/lvzip/source/lvzip.llb/ZLIB Locate File Only.vi
trunk/lvzip/source/lvzip.llb/ZLIB Locate File w. Info.vi
Added: trunk/lvzip/source/lvzip.llb/ZLIB Locate File Only.vi
===================================================================
(Binary files differ)
Index: trunk/lvzip/source/lvzip.llb/ZLIB Locate File Only.vi
===================================================================
--- trunk/lvzip/source/lvzip.llb/ZLIB Locate File Only.vi 2019-08-29 22:40:32 UTC (rev 1592)
+++ trunk/lvzip/source/lvzip.llb/ZLIB Locate File Only.vi 2019-08-31 22:52:12 UTC (rev 1593)
Property changes on: trunk/lvzip/source/lvzip.llb/ZLIB Locate File Only.vi
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Added: trunk/lvzip/source/lvzip.llb/ZLIB Locate File w. Info.vi
===================================================================
(Binary files differ)
Index: trunk/lvzip/source/lvzip.llb/ZLIB Locate File w. Info.vi
===================================================================
--- trunk/lvzip/source/lvzip.llb/ZLIB Locate File w. Info.vi 2019-08-29 22:40:32 UTC (rev 1592)
+++ trunk/lvzip/source/lvzip.llb/ZLIB Locate File w. Info.vi 2019-08-31 22:52:12 UTC (rev 1593)
Property changes on: trunk/lvzip/source/lvzip.llb/ZLIB Locate File w. Info.vi
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <lab...@us...> - 2019-08-29 22:40:34
|
Revision: 1592
http://sourceforge.net/p/opengtoolkit/svn/1592
Author: labviewer
Date: 2019-08-29 22:40:32 +0000 (Thu, 29 Aug 2019)
Log Message:
-----------
fix version string to add extra line feeds
Modified Paths:
--------------
trunk/lvzip/c_source/lvapi.c
Modified: trunk/lvzip/c_source/lvapi.c
===================================================================
--- trunk/lvzip/c_source/lvapi.c 2019-08-24 01:17:18 UTC (rev 1591)
+++ trunk/lvzip/c_source/lvapi.c 2019-08-29 22:40:32 UTC (rev 1592)
@@ -180,10 +180,10 @@
{
snprintf(version, sizeof(version), "LabVIEW ZIP library, version: 4.2, Dec 2018\n"
"zlib version: %s, build flags: 0x%lX\n"
- "minizip version: 1.2.0, September 16th, 2017"
+ "minizip version: 1.2.0, September 16th, 2017\n"
"aes version: 2013\n"
#ifdef HAVE_BZIP2
- "bzip2 version: %s"
+ "bzip2 version: %s\n"
#endif
, lvzip_zlibVersion(), lvzip_zlibCompileFlags()
#ifdef HAVE_BZIP2
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <lab...@us...> - 2019-08-24 01:17:19
|
Revision: 1591
http://sourceforge.net/p/opengtoolkit/svn/1591
Author: labviewer
Date: 2019-08-24 01:17:18 +0000 (Sat, 24 Aug 2019)
Log Message:
-----------
Recompilation of shared libraries
Modified Paths:
--------------
trunk/lvzip/RT Images/LinuxRT_arm/liblvzlib.so
trunk/lvzip/RT Images/LinuxRT_x64/liblvzlib.so
trunk/lvzip/RT Images/Pharlap/lvzlib.dll
trunk/lvzip/RT Images/vxworks61/lvzlib.out
trunk/lvzip/RT Images/vxworks63/lvzlib.out
Modified: trunk/lvzip/RT Images/LinuxRT_arm/liblvzlib.so
===================================================================
(Binary files differ)
Modified: trunk/lvzip/RT Images/LinuxRT_x64/liblvzlib.so
===================================================================
(Binary files differ)
Modified: trunk/lvzip/RT Images/Pharlap/lvzlib.dll
===================================================================
(Binary files differ)
Modified: trunk/lvzip/RT Images/vxworks61/lvzlib.out
===================================================================
(Binary files differ)
Modified: trunk/lvzip/RT Images/vxworks63/lvzlib.out
===================================================================
(Binary files differ)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <lab...@us...> - 2019-08-24 01:13:52
|
Revision: 1590
http://sourceforge.net/p/opengtoolkit/svn/1590
Author: labviewer
Date: 2019-08-24 01:13:50 +0000 (Sat, 24 Aug 2019)
Log Message:
-----------
Recompilation due to subVI changes
Modified Paths:
--------------
trunk/lvzip/tests/VI Tree.vi
trunk/lvzip/tests/lvzip-test-memory stream.vi
Modified: trunk/lvzip/tests/VI Tree.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/tests/lvzip-test-memory stream.vi
===================================================================
(Binary files differ)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <lab...@us...> - 2019-08-24 01:09:48
|
Revision: 1589
http://sourceforge.net/p/opengtoolkit/svn/1589
Author: labviewer
Date: 2019-08-24 01:09:46 +0000 (Sat, 24 Aug 2019)
Log Message:
-----------
Fix a crash due to alignment issues in certain LabVIEW versions
Modified Paths:
--------------
trunk/lvzip/source/lvzip.llb/ZLIB Close Zip Archive.vi
trunk/lvzip/source/lvzip.llb/ZLIB Convert File Info.vi
trunk/lvzip/source/lvzip.llb/ZLIB Copy Raw File.vi
trunk/lvzip/source/lvzip.llb/ZLIB Enumerate File Contents Old.vi
trunk/lvzip/source/lvzip.llb/ZLIB Extract File.vi
trunk/lvzip/source/lvzip.llb/ZLIB Extract Stream.vi
trunk/lvzip/source/lvzip.llb/ZLIB Extract.vi
trunk/lvzip/source/lvzip.llb/ZLIB Get Current File Info Old.vi
trunk/lvzip/source/lvzip.llb/ZLIB Get Current File Info.vi
trunk/lvzip/source/lvzip.llb/ZLIB Get Global Info.vi
trunk/lvzip/source/lvzip.llb/ZLIB Go To First File w Info.vi
trunk/lvzip/source/lvzip.llb/ZLIB Go To Next File w Info.vi
trunk/lvzip/source/lvzip.llb/ZLIB Locate File.vi
trunk/lvzip/source/lvzip.llb/ZLIB Open Unzip Stream.vi
trunk/lvzip/source/lvzip.llb/ZLIB Open Zip Archive.vi
trunk/lvzip/source/lvzip.llb/ZLIB Path to Path String.vi
trunk/lvzip/source/lvzip.llb/ZLIB Store Stream.vi
trunk/lvzip/source/lvzip.llb/ZLIB Uncompress File Info.ctl
trunk/lvzip/source/lvzip.llb/ZLIB VI Tree.vi
trunk/lvzip/source/lvzlib.dll
trunk/lvzip/source/lvzlib.so
trunk/lvzip/source/lvzlib64.dll
trunk/lvzip/source/lvzlib64.so
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Close Zip Archive.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Convert File Info.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Copy Raw File.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Enumerate File Contents Old.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Extract File.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Extract Stream.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Extract.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Get Current File Info Old.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Get Current File Info.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Get Global Info.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Go To First File w Info.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Go To Next File w Info.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Locate File.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Open Unzip Stream.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Open Zip Archive.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Path to Path String.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Store Stream.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB Uncompress File Info.ctl
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzip.llb/ZLIB VI Tree.vi
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzlib.dll
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzlib.so
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzlib64.dll
===================================================================
(Binary files differ)
Modified: trunk/lvzip/source/lvzlib64.so
===================================================================
(Binary files differ)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <lab...@us...> - 2019-08-24 01:04:53
|
Revision: 1588
http://sourceforge.net/p/opengtoolkit/svn/1588
Author: labviewer
Date: 2019-08-24 01:04:51 +0000 (Sat, 24 Aug 2019)
Log Message:
-----------
minor improvements trying to protect access to possible NULL pointers
Modified Paths:
--------------
trunk/lvzip/c_source/crypt.c
trunk/lvzip/c_source/iomem.c
trunk/lvzip/c_source/lvapi.c
trunk/lvzip/c_source/lvapi.h
trunk/lvzip/c_source/lvutil.c
trunk/lvzip/c_source/zlib.rc
Modified: trunk/lvzip/c_source/crypt.c
===================================================================
--- trunk/lvzip/c_source/crypt.c 2019-08-24 00:36:58 UTC (rev 1587)
+++ trunk/lvzip/c_source/crypt.c 2019-08-24 01:04:51 UTC (rev 1588)
@@ -36,6 +36,7 @@
# include <stdio.h>
# include <stdlib.h>
# include <sys/stat.h>
+# include <time.h>
# include <fcntl.h>
# include <unistd.h>
# include <dlfcn.h>
Modified: trunk/lvzip/c_source/iomem.c
===================================================================
--- trunk/lvzip/c_source/iomem.c 2019-08-24 00:36:58 UTC (rev 1587)
+++ trunk/lvzip/c_source/iomem.c 2019-08-24 01:04:51 UTC (rev 1588)
@@ -89,7 +89,7 @@
memio->error = 0;
if (opaque && !(mode & ZLIB_FILEFUNC_MODE_CREATE))
- memio->pos = LStrLen(*(LStrHandle)opaque);
+ memio->pos = LStrLenH((LStrHandle)opaque);
}
return memio;
}
@@ -115,8 +115,8 @@
if (mem->pos + size > 0x7FFFFFFF)
size = (uint32_t)(0x7FFFFFFF - mem->pos);
- if (mem->pos + size > (uint64_t)LStrLen(*(LStrHandle)opaque))
- size = (uint32_t)(LStrLen(*(LStrHandle)opaque) - mem->pos);
+ if (mem->pos + size > (uint64_t)LStrLenH((LStrHandle)opaque))
+ size = (uint32_t)(LStrLenH((LStrHandle)opaque) - mem->pos);
zmemcpy(buf, LStrBuf(*(LStrHandle)opaque) + mem->pos, size);
mem->pos += size;
@@ -206,9 +206,8 @@
start = mem->pos;
break;
case ZLIB_FILEFUNC_SEEK_END :
- if (opaque)
- start = LStrLen(*(LStrHandle)opaque);
- /* no break */
+ start = LStrLenH((LStrHandle)opaque);
+ /* no break */
case ZLIB_FILEFUNC_SEEK_SET :
break;
default:
Modified: trunk/lvzip/c_source/lvapi.c
===================================================================
--- trunk/lvzip/c_source/lvapi.c 2019-08-24 00:36:58 UTC (rev 1587)
+++ trunk/lvzip/c_source/lvapi.c 2019-08-24 01:04:51 UTC (rev 1588)
@@ -247,16 +247,19 @@
if (!err && comment)
{
int32 len = (int32)strlen(comment);
- err = NumericArrayResize(uB, 1, (UHandle*)globalcomment, len);
- if (!err)
+ if (len > 0)
{
- MoveBlock((ConstUPtr)comment, LStrBuf(**globalcomment), len);
- LStrLen(**globalcomment) = len;
+ err = NumericArrayResize(uB, 1, (UHandle*)globalcomment, len);
+ if (!err)
+ {
+ MoveBlock((ConstUPtr)comment, LStrBuf(**globalcomment), len);
+ LStrLen(**globalcomment) = len;
+ }
+ else
+ {
+ lvzlibDisposeRefnum(refnum, NULL, ZipMagic);
+ }
}
- else
- {
- lvzlibDisposeRefnum(refnum, NULL, ZipMagic);
- }
}
if (err)
{
@@ -319,13 +322,18 @@
LibAPI(MgErr) lvzlib_zipWriteInFileInZip(LVRefNum *refnum, const LStrHandle buffer)
{
- zipFile node;
- MgErr err = lvzlibGetRefnum(refnum, &node, ZipMagic);
- if (!err)
+ MgErr err = mgNoErr;
+ int32 len = LStrLenH(buffer);
+ if (len > 0)
{
- int retval = zipWriteInFileInZip(node, LStrBuf(*buffer), LStrLen(*buffer));
- if (retval < 0)
- return LibToMgErr(retval);
+ zipFile node;
+ err = lvzlibGetRefnum(refnum, &node, ZipMagic);
+ if (!err)
+ {
+ int retval = zipWriteInFileInZip(node, LStrBuf(*buffer), len);
+ if (retval < 0)
+ return LibToMgErr(retval);
+ }
}
return err;
}
@@ -442,16 +450,22 @@
err = LibToMgErr(unzGetGlobalInfo(node, &pglobal_info));
if (!err)
{
- err = NumericArrayResize(uB, 1, (UHandle*)comment, pglobal_info.size_comment);
- if (!err)
+ if (pglobal_info.size_comment)
{
- err = LibToMgErr(unzGetGlobalComment(node, (char*)LStrBuf(**comment), pglobal_info.size_comment));
+ err = NumericArrayResize(uB, 1, (UHandle*)comment, pglobal_info.size_comment + 1);
if (!err)
{
- LStrLen(**comment) = pglobal_info.size_comment;
- *nEntry = pglobal_info.number_entry;
+ err = LibToMgErr(unzGetGlobalComment(node, (char*)LStrBuf(**comment), pglobal_info.size_comment + 1));
}
}
+ if (*comment)
+ {
+ LStrLen(**comment) = pglobal_info.size_comment;
+ }
+ if (!err)
+ {
+ *nEntry = pglobal_info.number_entry;
+ }
}
}
return err;
@@ -467,21 +481,54 @@
err = LibToMgErr(unzGetGlobalInfo64(node, &pglobal_info));
if (!err)
{
- err = NumericArrayResize(uB, 1, (UHandle*)comment, pglobal_info.size_comment);
- if (!err)
+ if (pglobal_info.size_comment)
{
- err = LibToMgErr(unzGetGlobalComment(node, (char*)LStrBuf(**comment), pglobal_info.size_comment));
+ err = NumericArrayResize(uB, 1, (UHandle*)comment, pglobal_info.size_comment);
if (!err)
{
- LStrLen(**comment) = pglobal_info.size_comment;
- *nEntry = pglobal_info.number_entry;
+ err = LibToMgErr(unzGetGlobalComment(node, (char*)LStrBuf(**comment), pglobal_info.size_comment));
}
}
+ if (*comment)
+ {
+ LStrLen(**comment) = pglobal_info.size_comment;
+ }
+ if (!err)
+ {
+ *nEntry = pglobal_info.number_entry;
+ }
}
}
return err;
}
+static MgErr RetrieveFileInfo(unzFile node, unz_file_info *pfile_info, LStrHandle *fileName, uint16_t sizeFileName, LStrHandle *extraField, uint16_t sizeExtraField, LStrHandle *comment, uint16_t sizeComment)
+{
+ MgErr err = NumericArrayResize(uB, 1, (UHandle*)extraField, sizeExtraField + 1);
+ if (!err)
+ {
+ err = NumericArrayResize(uB, 1, (UHandle*)fileName, sizeFileName + 1);
+ if (!err)
+ {
+ err = NumericArrayResize(uB, 1, (UHandle*)comment, sizeComment + 1);
+ if (!err)
+ {
+ err = LibToMgErr(unzGetCurrentFileInfo(node, pfile_info, (char*)LStrBufH(*fileName), sizeFileName + 1, LStrBufH(*extraField), sizeExtraField + 1, (char*)LStrBufH(*comment), sizeComment + 1));
+ if (!err)
+ {
+ if (*extraField)
+ LStrLen(**extraField) = sizeExtraField;
+ if (*fileName)
+ LStrLen(**fileName) = sizeFileName;
+ if (*comment)
+ LStrLen(**comment) = sizeComment;
+ }
+ }
+ }
+ }
+ return err;
+}
+
/****************************************************************************************************
*
* Position the current file pointer to the file with fileName
@@ -557,25 +604,37 @@
return err;
}
-static MgErr RetrieveFileInfo(unzFile node, unz_file_info *pfile_info, LStrHandle *fileName, uint16_t sizeFileName, LStrHandle *extraField, uint16_t sizeExtraField, LStrHandle *comment, uint16_t sizeComment)
+MgErr lvzlib_unzLocateFile2_64(LVRefNum *refnum, unz_file_info64 *pfile_info, LStrHandle *fileName, LStrHandle *extraField, LStrHandle *comment, int iCaseSensitivity)
{
- MgErr err = NumericArrayResize(uB, 1, (UHandle*)extraField, sizeExtraField);
+ unzFile node;
+ MgErr err = lvzlibGetRefnum(refnum, &node, UnzMagic);
if (!err)
{
- err = NumericArrayResize(uB, 1, (UHandle*)fileName, sizeFileName);
+ err = ZeroTerminateLString(fileName);
if (!err)
{
- err = NumericArrayResize(uB, 1, (UHandle*)comment, sizeComment);
+ unzFileNameComparer filename_compare_func = NULL;
+ if (
+#if Mac || MSWin || VxWorks
+ !iCaseSensitivity ||
+#endif
+ iCaseSensitivity == 2)
+ {
+ filename_compare_func = caseInsensitiveNameComparer;
+ }
+ else
+ {
+ filename_compare_func = caseSensitiveNameComparer;
+ }
+ err = LibToMgErr(unzLocateFile(node, (const char*)LStrBufH(*fileName), filename_compare_func));
if (!err)
{
- err = LibToMgErr(unzGetCurrentFileInfo(node, pfile_info, (char*)LStrBuf(**fileName), sizeFileName, LStrBuf(**extraField), sizeExtraField, (char*)LStrBuf(**comment), sizeComment));
+ err = LibToMgErr(unzGetCurrentFileInfo64(node, pfile_info, NULL, 0, NULL, 0, NULL, 0));
if (!err)
{
- LStrLen(**extraField) = sizeExtraField;
- LStrLen(**fileName) = sizeFileName;
- LStrLen(**comment) = sizeComment;
+ err = RetrieveFileInfo(node, NULL, fileName, pfile_info->size_filename, extraField, pfile_info->size_file_extra, comment, pfile_info->size_file_comment);
}
- }
+ }
}
}
return err;
@@ -673,13 +732,15 @@
err = NumericArrayResize(uB, 1, (UHandle*)extra, len);
if (!err)
{
- err = LibToMgErr(unzGetLocalExtrafield(node, LStrBuf(**extra), len));
- if (!err)
- LStrLen(**extra) = len;
+ LStrLen(**extra) = unzGetLocalExtrafield(node, LStrBuf(**extra), len);
}
- return err;
}
- err = LibToMgErr(len);
+ else
+ {
+ err = LibToMgErr(len);
+ }
+ if (*extra)
+ LStrLen(**extra) = 0;
}
return err;
}
@@ -698,7 +759,7 @@
{
unzFile node;
MgErr err = lvzlibGetRefnum(refnum, &node, UnzMagic);
- if (!err)
+ if (!err && buffer)
{
int retval = unzReadCurrentFile(node, LStrBuf(*buffer), LStrLen(*buffer));
if (retval < 0)
Modified: trunk/lvzip/c_source/lvapi.h
===================================================================
--- trunk/lvzip/c_source/lvapi.h 2019-08-24 00:36:58 UTC (rev 1587)
+++ trunk/lvzip/c_source/lvapi.h 2019-08-24 01:04:51 UTC (rev 1588)
@@ -52,6 +52,7 @@
LibAPI(MgErr) lvzlib_unzGetGlobalInfo32(LVRefNum *refnum, LStrHandle *comment, uInt32 *nEntry);
LibAPI(MgErr) lvzlib_unzGetGlobalInfo64(LVRefNum *refnum, LStrHandle *comment, uInt64 *nEntry);
LibAPI(MgErr) lvzlib_unzLocateFile(LVRefNum *refnum, LStrHandle fileName, int iCaseSensitivity);
+LibAPI(MgErr) lvzlib_unzLocateFile2_64(LVRefNum *refnum, unz_file_info64 *pfile_info, LStrHandle *fileName, LStrHandle *extraField, LStrHandle *comment, int iCaseSensitivity);
LibAPI(MgErr) lvzlib_unzGetCurrentFileInfo32(LVRefNum *refnum, unz_file_info *pfile_info, LStrHandle *fileName, LStrHandle *extraField, LStrHandle *comment);
LibAPI(MgErr) lvzlib_unzGetCurrentFileInfo64(LVRefNum *refnum, unz_file_info64 *pfile_info, LStrHandle *fileName, LStrHandle *extraField, LStrHandle *comment);
LibAPI(MgErr) lvzlib_unzOpenCurrentFile(LVRefNum *refnum, int32* method, int32* level, int16 raw, const char* password);
Modified: trunk/lvzip/c_source/lvutil.c
===================================================================
--- trunk/lvzip/c_source/lvutil.c 2019-08-24 00:36:58 UTC (rev 1587)
+++ trunk/lvzip/c_source/lvutil.c 2019-08-24 01:04:51 UTC (rev 1588)
@@ -1373,7 +1373,7 @@
{
DEBUGPRINTF(("FSSetCatalogInfo: err = %ld", err));
}
- else if (LStrLen(*comment) > 0)
+ else if (LStrLenH(comment) > 0)
{
/* Ignore error for getting Desktop comments */
ret = OSErrToLVErr(PBDTGetPath(&dtpb));
@@ -1629,7 +1629,7 @@
LStrHandle hfsPath = NULL;
/* Convert the posix path to an HFS path */
err = ConvertFromPosixPath(str, len, CP_ACP, &hfsPath, CP_ACP, '?', NULL, isDir);
- if (!err)
+ if (!err && hsfPath)
{
err = FTextToPath(LStrBuf(*hfsPath), LStrLen(*hfsPath), path);
}
@@ -2817,7 +2817,7 @@
LibAPI(MgErr) ConvertCString(ConstCStr src, int32 srclen, uInt32 srccp, LStrHandle *dest, uInt32 destcp, char defaultChar, LVBoolean *defUsed)
{
- MgErr err;
+ MgErr err = noErr;
if (srccp != destcp)
{
UStrHandle ustr = NULL;
@@ -2833,12 +2833,15 @@
{
if (srclen == -1)
srclen = StrLen(src);
- err = NumericArrayResize(uB, 1, (UHandle*)dest, srclen);
- if (!err)
+ if (srclen > 0)
{
- MoveBlock(src, LStrBuf(**dest), srclen);
- LStrLen(**dest) = srclen;
- return err;
+ err = NumericArrayResize(uB, 1, (UHandle*)dest, srclen);
+ if (!err)
+ {
+ MoveBlock(src, LStrBuf(**dest), srclen);
+ LStrLen(**dest) = srclen;
+ return err;
+ }
}
}
if (*dest)
@@ -2853,7 +2856,7 @@
#if usesWinPath
Unused(isDir);
err = ConvertCString(src, srclen, srccp, dest, destcp, defaultChar, defUsed);
- if (!err)
+ if (!err && *dest)
{
int32 len = LStrLen(**dest);
UPtr buf = LStrBuf(**dest);
@@ -2979,7 +2982,7 @@
#if usesWinPath
Unused(isDir);
err = ConvertLString(src, srccp, dest, destcp, defaultChar, defUsed);
- if (!err)
+ if (!err && *dest)
{
int32 len = LStrLen(**dest);
UPtr buf = LStrBuf(**dest);
@@ -3340,7 +3343,7 @@
LibAPI(MgErr) ZeroTerminateLString(LStrHandle *dest)
{
- int32 size = dest ? LStrLen(**dest) : 0;
+ int32 size = LStrLenH(*dest);
MgErr err = NumericArrayResize(uB, 1, (UHandle*)dest, size + 1);
if (!err)
LStrBuf(**dest)[size] = 0;
Modified: trunk/lvzip/c_source/zlib.rc
===================================================================
--- trunk/lvzip/c_source/zlib.rc 2019-08-24 00:36:58 UTC (rev 1587)
+++ trunk/lvzip/c_source/zlib.rc 2019-08-24 01:04:51 UTC (rev 1588)
@@ -2,8 +2,8 @@
#define IDR_VERSION1 1
IDR_VERSION1 VERSIONINFO MOVEABLE IMPURE LOADONCALL DISCARDABLE
- FILEVERSION 4,1,0
- PRODUCTVERSION 4,1,0
+ FILEVERSION 4,2,0
+ PRODUCTVERSION 4,2,0
FILEFLAGSMASK VS_FFI_FILEFLAGSMASK
FILEFLAGS 0
FILEOS VOS_DOS_WINDOWS32
@@ -17,12 +17,12 @@
BEGIN
VALUE "FileDescription", "LabVIEW zlib data compression library\0"
- VALUE "FileVersion", "4.1.0.LV7\0"
+ VALUE "FileVersion", "4.2.0.LV7\0"
VALUE "InternalName", "lvzlib\0"
VALUE "OriginalFilename", "lvzlib.dll\0"
VALUE "ProductName", "LVZLib.DLL\0"
- VALUE "Comments","DLL support by Alessandro Iacopetti & Gilles Vollant\r\nZIP support by Gilles Vollant\r\nLabVIEW support by Rolf Kalbermatter\r\nBased on zlib 1.2.8 and minizip 1.1\0"
- VALUE "LegalCopyright", "(C) 1995-2014 Jean-loup Gailly & Mark Adler\0"
+ VALUE "Comments","DLL support by Alessandro Iacopetti & Gilles Vollant\r\nZIP support by Gilles Vollant\r\nLabVIEW support by Rolf Kalbermatter\r\nBased on zlib 1.2.11 and minizip 1.2\0"
+ VALUE "LegalCopyright", "(C) 1995-2017 Jean-loup Gailly & Mark Adler\0"
END
END
BLOCK "VarFileInfo"
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|