Index: /trunk/include/iprt/path.h
===================================================================
--- /trunk/include/iprt/path.h	(revision 19927)
+++ /trunk/include/iprt/path.h	(revision 19928)
@@ -349,12 +349,15 @@
  * concatenating the two partial paths.
  *
- * @returns IPRT status code.
- * @retval  VERR_PATH
+ * @retval  VINF_SUCCESS on success.
+ * @retval  VERR_BUFFER_OVERFLOW if the result is too big to fit within
+ *          cbPathDst bytes. No changes has been made.
+ * @retval  VERR_INVALID_PARAMETER if the string pointed to by pszPath is longer
+ *          than cbPathDst-1 bytes (failed to find terminator). Asserted.
  *
  * @param   pszPath         The path to append pszAppend to. This serves as both
  *                          input and output. This can be empty, in which case
  *                          pszAppend is just copied over.
- * @param   cchPathDst      The size of the buffer pszPath points to. This
- *                          should NOT be strlen(pszPath).
+ * @param   cbPathDst       The size of the buffer pszPath points to, terminator
+ *                          included. This should NOT be strlen(pszPath).
  * @param   pszAppend       The partial path to append to pszPath. This can be
  *                          NULL, in which case nothing is done.
@@ -371,5 +374,5 @@
  *          sizeof(szBuf), "bar") will result in "C:bar".
  */
-RTDECL(int) RTPathAppend(char *pszPath, size_t cchPathDst, const char *pszAppend);
+RTDECL(int) RTPathAppend(char *pszPath, size_t cbPathDst, const char *pszAppend);
 
 
Index: /trunk/src/VBox/Runtime/r3/path.cpp
===================================================================
--- /trunk/src/VBox/Runtime/r3/path.cpp	(revision 19927)
+++ /trunk/src/VBox/Runtime/r3/path.cpp	(revision 19928)
@@ -729,7 +729,7 @@
 
 
-RTDECL(int) RTPathAppend(char *pszPath, size_t cchPath, const char *pszAppend)
-{
-    char *pszPathEnd = (char *)memchr(pszPath, '\0', cchPath);
+RTDECL(int) RTPathAppend(char *pszPath, size_t cbPathDst, const char *pszAppend)
+{
+    char *pszPathEnd = (char *)memchr(pszPath, '\0', cbPathDst);
     AssertReturn(pszPathEnd, VERR_INVALID_PARAMETER);
 
@@ -744,5 +744,5 @@
     if (pszPathEnd == pszPath)
     {
-        if (cchAppend >= cchPath)
+        if (cchAppend >= cbPathDst)
             return VERR_BUFFER_OVERFLOW;
         memcpy(pszPath, pszAppend, cchAppend + 1);
@@ -762,5 +762,5 @@
                 &&  RT_C_IS_ALPHA(pszPath[0]))
             {
-                if ((size_t)(pszPathEnd - pszPath) + cchAppend >= cchPath)
+                if ((size_t)(pszPathEnd - pszPath) + cchAppend >= cbPathDst)
                     return VERR_BUFFER_OVERFLOW;
             }
@@ -768,5 +768,5 @@
 #endif
             {
-                if ((size_t)(pszPathEnd - pszPath) + 1 + cchAppend >= cchPath)
+                if ((size_t)(pszPathEnd - pszPath) + 1 + cchAppend >= cbPathDst)
                     return VERR_BUFFER_OVERFLOW;
                 *pszPathEnd++ = '/';
@@ -779,5 +779,5 @@
                 pszAppend++, cchAppend--;
 
-            if ((size_t)(pszPathEnd - pszPath) + cchAppend >= cchPath)
+            if ((size_t)(pszPathEnd - pszPath) + cchAppend >= cbPathDst)
                 return VERR_BUFFER_OVERFLOW;
         }
@@ -796,5 +796,5 @@
             pszPathEnd--;
 
-        if ((size_t)(pszPathEnd - pszPath) + cchAppend >= cchPath)
+        if ((size_t)(pszPathEnd - pszPath) + cchAppend >= cbPathDst)
             return VERR_BUFFER_OVERFLOW;
     }
