posts - 2,  comments - 0,  trackbacks - 0
        C++通过webservices将转成base64编码的图片数据发送给java,可是java那边显示出来的图片是全绿色的,后来寻找大牛帮忙才发现C++转的base64图片信息是包含“+”的,而UTF-8编码的java工程是不识别“+”的,需要转成%2B,将转码后的信息用%2B转化“+”果然解决问题。
posted @ 2012-08-07 21:43 杨俊 阅读(1406) | 评论 (0)编辑 收藏
      PulseEvent是将指定的事件设为有信号状态,如果是一个人工重设事件,正在等候事件的、被挂起的所有线程都会进入活动状态,函数随后将事件设回,并返回;如果是一个自动重设事件,则正在等候事件的、被挂起的单个线程会进入活动状态,事件随后设回无信号,并且函数返回。
      但是等待线程必须在PulseEvent的一个脉冲时正在等待才能被激活。
        While the thread is sitting waiting for the event, a device driver or part of the kernel itself might ask to borrow the thread to do some processing (by means of a "kernel-mode APC"). During that time, the thread is not in the wait state. (It's being used by the device driver.) If the PulseEvent happens while the thread is being "borrowed", then it will not be woken from the wait, because the PulseEvent function wakes only threads that were waiting at the time the PulseEvent occurs.
      一个线程处于等待状态的过程中,会有一些瞬间其状态并不为“等待状态”。这就造成PulseEvent()不能激活应该被激活的等待线程。
     这些瞬间包括什么呢?比如发生了系统调用,缺页中断,硬件中断......等等。
posted @ 2012-07-13 23:55 杨俊 阅读(532) | 评论 (0)编辑 收藏
仅列出标题  
<2024年4月>
31123456
78910111213
14151617181920
21222324252627
2829301234
567891011

常用链接

留言簿

随笔档案

搜索

  •  

最新评论

阅读排行榜

评论排行榜