\0 delimeter issue fixed
This commit is contained in:
		@@ -70,9 +70,9 @@ void getcmd(const Block *block, char *output)
 | 
				
			|||||||
		pclose(cmdf);
 | 
							pclose(cmdf);
 | 
				
			||||||
		return;
 | 
							return;
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
	if (delim[0] != '\0') {
 | 
					 | 
				
			||||||
	//only chop off newline if one is present at the end
 | 
						//only chop off newline if one is present at the end
 | 
				
			||||||
	i = output[i-1] == '\n' ? i-1 : i;
 | 
						i = output[i-1] == '\n' ? i-1 : i;
 | 
				
			||||||
 | 
						if (delim[0] != '\0') {
 | 
				
			||||||
		strncpy(output+i, delim, delimLen); 
 | 
							strncpy(output+i, delim, delimLen); 
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
	else
 | 
						else
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user