Initially a Linux command-line interface blog, it has evolved to cover increasingly more GUI app topics. Instead of just giving you information like some man page, I illustrate their usage in real-life scenarios. How can we determine when a running process was started? The venerable ps command deserves first consideration. Most Linux command-line users are familiar with either the standard UNIX no
仮想デバイスドライバを利用したプロセス間通信について September 11, 2006 Posted by butcher in : C, Operating System , trackback 仮想デバイスドライバを利用したプロセス間通信について説明します。といってもよくわからないと思うので、ちゃんと説明します。 Unixでプロセス間通信というと、ソケットを使ったもの、パイプを使ったもの、共有メモリを使ったもの等がありますが、それぞれ長所・短所があると思います。 ものすごく簡単に言うと、 ソケットでは、 複数マシン間での通信が可能 通信処理のオーバーヘッドが大きい(コネクション開始・終了処理も含め) パイプでは、 ソケットより通信処理のオーバーヘッドが少ない 親子関係のプロセスに限定される 共有メモリでは、 シンプルで高速 書き込み・読み取りの同期をとるのが難しい 等が
所用で「あるプロセスから別のプロセスを終了させるプログラム」を書いていました.終了させる部分の関数は以下のような感じ. #include <string> #include <vector> #include <windows.h> #include <tchar.h> #include <psapi.h> #pragma comment(lib, "psapi.lib") namespace process { std::size_t kill(const std::basic_string<TCHAR>& name) { std::size_t result = 0; std::vector<DWORD> processes(256, 0); DWORD procbytes = 0; while (1) { if (!::EnumProcesses(reinterpret_cast<D
Blogged by Ujihisa. Standard methods of programming and thoughts including Clojure, Vim, LLVM, Haskell, Ruby and Mathematics written by a Japanese programmer. github/ujihisa Spawn = Fork + Exec, but works also on platforms which don't support fork. The usage of spawn is often said to be cryptic. Here I'll describe common cases. system('ls') pid = spawn(['ls', 'ls']) Process.wait(pid) system('ls .'
CreateProcess関数を使ってメモ帳を起動したいのですが、 PROCESS_INFORMATION pi; STARTUPINFO si; CreateProcess関数を使ってメモ帳を起動したいのですが、 PROCESS_INFORMATION pi; STARTUPINFO si; CreateProcess関数を使ってメモ帳を起動したいのですが、 PROCESS_INFORMATION pi; STARTUPINFO si; ZeroMemory(&si,sizeof(si)); si.cb=sizeof(si); CreateProcess(NULL,(LPTSTR)"C:\\Documents and Settings\\Administrator\\My Documents\\text.txt",NULL,NULL,FALSE,NORMAL_PRIORITY_CLASS
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く