- Timestamp:
- Apr 8, 2016 9:47:08 AM (9 years ago)
- svn:sync-xref-src-repo-rev:
- 106479
- Location:
- trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/iprt/linux/sysfs.h
r60390 r60393 364 364 * @param ... Format args. 365 365 */ 366 RTDECL(int) RTLinuxSysFs ReadStrFile(char *pszBuf, size_t cchBuf, size_t *pcchWritten, const char *pszFormat, ...) RT_IPRT_FORMAT_ATTR(4, 5);366 RTDECL(int) RTLinuxSysFsWriteStrFile(const char *pszBuf, size_t cchBuf, size_t *pcchWritten, const char *pszFormat, ...) RT_IPRT_FORMAT_ATTR(4, 5); 367 367 368 368 /** -
trunk/src/VBox/Runtime/r3/linux/sysfs.cpp
r60390 r60393 394 394 } 395 395 396 int rc = RTLinuxSysFsOpen V(&hFile, pszFormat, va);396 int rc = RTLinuxSysFsOpenExV(&hFile, RTFILE_O_OPEN | RTFILE_O_WRITE | RTFILE_O_DENY_NONE, pszFormat, va); 397 397 if (RT_SUCCESS(rc)) 398 398 { … … 518 518 519 519 520 RTDECL(int) RTLinuxSysFsWriteStrFileV(const char *pszBuf, size_t cchBuf, size_t *pcchWritten, const char *pszFormat, va_list va) 521 { 522 RTFILE hFile; 523 524 AssertPtrReturn(pszBuf, VERR_INVALID_POINTER); 525 526 int rc = RTLinuxSysFsOpenExV(&hFile, RTFILE_O_OPEN | RTFILE_O_WRITE | RTFILE_O_DENY_NONE, pszFormat, va); 527 if (RT_SUCCESS(rc)) 528 { 529 rc = RTLinuxSysFsWriteStr(hFile, pszBuf, cchBuf, pcchWritten); 530 RTFileClose(hFile); 531 } 532 return rc; 533 } 534 535 536 RTDECL(int) RTLinuxSysFsWriteStrFile(const char *pszBuf, size_t cchBuf, size_t *pcchWritten, const char *pszFormat, ...) 537 { 538 va_list va; 539 va_start(va, pszFormat); 540 int rc = RTLinuxSysFsWriteStrFileV(pszBuf, cchBuf, pcchWritten, pszFormat, va); 541 va_end(va); 542 return rc; 543 } 544 520 545 RTDECL(int) RTLinuxSysFsGetLinkDestV(char *pszBuf, size_t cchBuf, size_t *pchBuf, const char *pszFormat, va_list va) 521 546 {
Note:
See TracChangeset
for help on using the changeset viewer.