From 8cf58297d9743bdbfdddb605cc9cefe0c6273ee5 Mon Sep 17 00:00:00 2001 From: Denys Vlasenko Date: Thu, 21 Jan 2010 18:45:21 +0100 Subject: TicketUploader and FileTransfer plugins: fixes after a round of testing for one, FileTransfer now would not use current dir as a storage for temp files. Signed-off-by: Denys Vlasenko --- lib/Plugins/CCpp.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'lib/Plugins/CCpp.cpp') diff --git a/lib/Plugins/CCpp.cpp b/lib/Plugins/CCpp.cpp index 28e6bac..5838bc4 100644 --- a/lib/Plugins/CCpp.cpp +++ b/lib/Plugins/CCpp.cpp @@ -417,9 +417,7 @@ static void InstallDebugInfos(const char *pDebugDumpDir, char buff[1024]; while (fgets(buff, sizeof(buff), pipeout_fp)) { - int last = strlen(buff) - 1; - if (last >= 0 && buff[last] == '\n') - buff[last] = '\0'; + strchrnul(buff, '\n')[0] = '\0'; if (strncmp(buff, "MISSING:", 8) == 0) { -- cgit