Title: [216040] trunk/Source/WebCore
Revision
216040
Author
[email protected]
Date
2017-05-01 15:55:38 -0700 (Mon, 01 May 2017)

Log Message

Stop using strcpy() in fullyQualifiedInfoTableName() from Database.cpp
<https://webkit.org/b/171517>

Reviewed by Brady Eidson.

* Modules/webdatabase/Database.cpp:
(WebCore::fullyQualifiedInfoTableName): Switch from strcpy() to
snprintf().

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (216039 => 216040)


--- trunk/Source/WebCore/ChangeLog	2017-05-01 22:54:19 UTC (rev 216039)
+++ trunk/Source/WebCore/ChangeLog	2017-05-01 22:55:38 UTC (rev 216040)
@@ -1,3 +1,14 @@
+2017-05-01  David Kilzer  <[email protected]>
+
+        Stop using strcpy() in fullyQualifiedInfoTableName() from Database.cpp
+        <https://webkit.org/b/171517>
+
+        Reviewed by Brady Eidson.
+
+        * Modules/webdatabase/Database.cpp:
+        (WebCore::fullyQualifiedInfoTableName): Switch from strcpy() to
+        snprintf().
+
 2017-05-01  Chris Fleizach  <[email protected]>
 
         AX: Support time@datetime for verbosity clarification of dates, times, and durations

Modified: trunk/Source/WebCore/Modules/webdatabase/Database.cpp (216039 => 216040)


--- trunk/Source/WebCore/Modules/webdatabase/Database.cpp	2017-05-01 22:54:19 UTC (rev 216039)
+++ trunk/Source/WebCore/Modules/webdatabase/Database.cpp	2017-05-01 22:55:38 UTC (rev 216040)
@@ -99,8 +99,7 @@
 
     static std::once_flag onceFlag;
     std::call_once(onceFlag, [] {
-        strcpy(qualifiedName, qualifier);
-        strcpy(qualifiedName + sizeof(qualifier) - 1, unqualifiedInfoTableName);
+        snprintf(qualifiedName, sizeof(qualifiedName), "%s%s", qualifier, unqualifiedInfoTableName);
     });
 
     return qualifiedName;
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to