diff options
author | Kirill Volinsky <mataes2007@gmail.com> | 2013-07-24 14:52:01 +0000 |
---|---|---|
committer | Kirill Volinsky <mataes2007@gmail.com> | 2013-07-24 14:52:01 +0000 |
commit | 3e02ce14f6cce63910b266655a9c33bd3a70f17a (patch) | |
tree | 8fcf4371ea0d10693e7697f305d51988484faf69 /plugins/FloatingContacts | |
parent | 107471fac771abe5774d10769e36c0903a908685 (diff) |
replace sprintf to mir_snprintf (part 4)
git-svn-id: http://svn.miranda-ng.org/main/trunk@5467 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/FloatingContacts')
-rw-r--r-- | plugins/FloatingContacts/src/filedrop.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/plugins/FloatingContacts/src/filedrop.cpp b/plugins/FloatingContacts/src/filedrop.cpp index 87a6c1afe3..9d83459efb 100644 --- a/plugins/FloatingContacts/src/filedrop.cpp +++ b/plugins/FloatingContacts/src/filedrop.cpp @@ -228,7 +228,8 @@ static int CountFiles( char *szItem ) if ( NULL != strstr( szItem, "*.*" ))
{
- sprintf( szDirName + strlen( szDirName ) - 3, "%s\0", fd.cFileName );
+ size_t offset = strlen( szDirName ) - 3;
+ mir_snprintf(szDirName + offset, SIZEOF( szDirName) - offset, "%s\0", fd.cFileName);
}
++nCount;
@@ -269,7 +270,8 @@ static void SaveFiles( char *szItem, char **ppFiles, int *pnCount ) if ( NULL != strstr( szItem, "*.*" ))
{
- sprintf( szDirName + strlen( szDirName ) - 3, "%s\0", fd.cFileName );
+ size_t offset = strlen( szDirName ) - 3;
+ mir_snprintf(szDirName + offset, SIZEOF( szDirName) - offset, "%s\0", fd.cFileName);
}
ppFiles[ *pnCount ] = _strdup( szDirName );
|