add: if (status >= 0 && bufferSize > 0) { if (status < (int)bufferSize) buffer[status] = '\0'; else buffer[bufferSize - 1] = '\0'; }
context: common_read_link(int fd, char *path, char *buffer, size_t bufferSize,	bool kernel){	struct vnode *vnode;	int status;	status = fd_and_path_to_vnode(fd, path, false, &vnode, kernel);	if (status < B_OK)		return status;	if (FS_CALL(vnode, read_link) != NULL)		status = FS_CALL(vnode, read_link)(vnode->mount->cookie, vnode->private_node, buffer, bufferSize);	else		status = B_BAD_VALUE;	put_vnode(vnode);	return status;}