我有一个内核模块,该模块在初始化例程中有一个while(1)循环,该循环应该无限运行。
如果我在用户空间程序中有等效的代码,则当我按Control + C时,用户空间程序将终止,但是内核模块不是这种情况。
有没有办法向内核模块发送终止信号(当它仍在运行其init例程时),以便它可以终止/退出?
提前致谢
嗨,我正在尝试将一个表格从 docx 文件复制到另一个文件,但发生的情况是表格的值被复制到新文档中的表格下方和表格之外(见下图)
新 docx 中的 Talbe
如您所见,表的值被复制到表外。我使用的是 Libre Office,apache poi 版本 3.17,我的电脑运行的是 Ubuntu 16.04
我用来执行复制的代码如下
public static void copyTable(XWPFDocument input_doc,XWPFDocument output_doc,
int table_index_input, int table_index_output) {
XWPFTable template_table = input_doc.getTables().get(table_index_input);
CTTbl ctTbl = CTTbl.Factory.newInstance(); // Create a new CTTbl for the new table
ctTbl.set(template_table.getCTTbl()); // Copy the template table's CTTbl
XWPFTable new_table = new XWPFTable(ctTbl, output_doc); // Create a new table using the CTTbl upon
output_doc.createParagraph();
output_doc.createTable();// Create a empty table in the document
output_doc.setTable(table_index_output, new_table); // Replace …Run Code Online (Sandbox Code Playgroud)